

<!DOCTYPE html>
<html lang="zh-CN" data-default-color-scheme=auto>



<head>
  <meta charset="UTF-8">
  <link rel="apple-touch-icon" sizes="76x76" href="/img/Mine.jpg">
  <link rel="icon" href="/img/Mine.jpg">
  <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=5.0, shrink-to-fit=no">
  <meta http-equiv="x-ua-compatible" content="ie=edge">
  
  <meta name="theme-color" content="#2f4154">
  <meta name="author" content="Chiam">
  <meta name="keywords" content="算法，安全">
  
    <meta name="description" content="『C++&amp;C 语言』C++课程设计，12306 模拟写起来就是这么粗暴这篇文章很详细，也很多希望可以好好看看！看完 C++稳过！一、12306 应该具备那些功能 1.查询（一个月以内的）： 1.查车票：出发地+目的地+出发时间-&gt;显示经过两站车票信息（余票，车次信息可直接查询直接打印，是否为过路车，历时不是总历时，是两站间历时）（只有这种查询方式能查询余票） 2.车站车次查询：车站+">
<meta property="og:type" content="article">
<meta property="og:title" content="『C++&amp;C语言』C++课程设计，12306模拟写起来就是这么粗暴">
<meta property="og:url" content="http://example.com/2023/12/06/%E3%80%8EC++&C%E8%AF%AD%E8%A8%80%E3%80%8FC++%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1%EF%BC%8C12306%E6%A8%A1%E6%8B%9F%E5%86%99%E8%B5%B7%E6%9D%A5%E5%B0%B1%E6%98%AF%E8%BF%99%E4%B9%88%E7%B2%97%E6%9A%B4/index.html">
<meta property="og:site_name" content="Chiam 的个人主页">
<meta property="og:description" content="『C++&amp;C 语言』C++课程设计，12306 模拟写起来就是这么粗暴这篇文章很详细，也很多希望可以好好看看！看完 C++稳过！一、12306 应该具备那些功能 1.查询（一个月以内的）： 1.查车票：出发地+目的地+出发时间-&gt;显示经过两站车票信息（余票，车次信息可直接查询直接打印，是否为过路车，历时不是总历时，是两站间历时）（只有这种查询方式能查询余票） 2.车站车次查询：车站+">
<meta property="og:locale" content="zh_CN">
<meta property="article:published_time" content="2023-12-05T16:11:43.630Z">
<meta property="article:modified_time" content="2023-12-05T16:17:40.332Z">
<meta property="article:author" content="Chiam">
<meta property="article:tag" content="算法，安全">
<meta name="twitter:card" content="summary_large_image">
  
  
  
  <title>『C++&amp;C语言』C++课程设计，12306模拟写起来就是这么粗暴 - Chiam 的个人主页</title>

  <link  rel="stylesheet" href="https://lib.baomitu.com/twitter-bootstrap/4.6.1/css/bootstrap.min.css" />



  <link  rel="stylesheet" href="https://lib.baomitu.com/github-markdown-css/4.0.0/github-markdown.min.css" />

  <link  rel="stylesheet" href="https://lib.baomitu.com/hint.css/2.7.0/hint.min.css" />

  <link  rel="stylesheet" href="https://lib.baomitu.com/fancybox/3.5.7/jquery.fancybox.min.css" />



<!-- 主题依赖的图标库，不要自行修改 -->
<!-- Do not modify the link that theme dependent icons -->

<link rel="stylesheet" href="//at.alicdn.com/t/font_1749284_hj8rtnfg7um.css">



<link rel="stylesheet" href="//at.alicdn.com/t/font_1736178_lbnruvf0jn.css">


<link  rel="stylesheet" href="/css/main.css" />


  <link id="highlight-css" rel="stylesheet" href="/css/highlight.css" />
  
    <link id="highlight-css-dark" rel="stylesheet" href="/css/highlight-dark.css" />
  



  
<link rel="stylesheet" href="/css/custom.css">



  <script id="fluid-configs">
    var Fluid = window.Fluid || {};
    Fluid.ctx = Object.assign({}, Fluid.ctx)
    var CONFIG = {"hostname":"example.com","root":"/","version":"1.9.5-a","typing":{"enable":true,"typeSpeed":70,"cursorChar":"_","loop":false,"scope":[]},"anchorjs":{"enable":true,"element":"h1,h2,h3,h4,h5,h6","placement":"left","visible":"hover","icon":"❡"},"progressbar":{"enable":true,"height_px":3,"color":"#29d","options":{"showSpinner":false,"trickleSpeed":100}},"code_language":{"enable":true,"default":"TEXT"},"copy_btn":true,"image_caption":{"enable":true},"image_zoom":{"enable":true,"img_url_replace":["",""]},"toc":{"enable":true,"placement":"right","headingSelector":"h1,h2,h3,h4,h5,h6","collapseDepth":2},"lazyload":{"enable":true,"loading_img":"/img/loading.gif","onlypost":false,"offset_factor":2},"web_analytics":{"enable":false,"follow_dnt":true,"baidu":null,"google":{"measurement_id":null},"tencent":{"sid":null,"cid":null},"woyaola":null,"cnzz":null,"leancloud":{"app_id":null,"app_key":null,"server_url":null,"path":"window.location.pathname","ignore_local":false}},"search_path":"/local-search.xml","include_content_in_search":true};

    if (CONFIG.web_analytics.follow_dnt) {
      var dntVal = navigator.doNotTrack || window.doNotTrack || navigator.msDoNotTrack;
      Fluid.ctx.dnt = dntVal && (dntVal.startsWith('1') || dntVal.startsWith('yes') || dntVal.startsWith('on'));
    }
  </script>
  <script  src="/js/utils.js" ></script>
  <script  src="/js/color-schema.js" ></script>
  


  
<meta name="generator" content="Hexo 6.3.0"></head>


<body>
  

  <header>
    

<div class="header-inner" style="height: 70vh;">
  <nav id="navbar" class="navbar fixed-top  navbar-expand-lg navbar-dark scrolling-navbar">
  <div class="container">
    <a class="navbar-brand" href="/">
      <strong>Chiam&#39;s Blogs</strong>
    </a>

    <button id="navbar-toggler-btn" class="navbar-toggler" type="button" data-toggle="collapse"
            data-target="#navbarSupportedContent"
            aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
      <div class="animated-icon"><span></span><span></span><span></span></div>
    </button>

    <!-- Collapsible content -->
    <div class="collapse navbar-collapse" id="navbarSupportedContent">
      <ul class="navbar-nav ml-auto text-center">
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/">
                
                <span>首页</span>
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/archives/">
                
                <span>归档</span>
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/categories/">
                
                <span>分类</span>
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/about/">
                
                <span>关于</span>
              </a>
            </li>
          
        
          
          
          
          
            <li class="nav-item">
              <a class="nav-link" href="/links/">
                
                <span>友链</span>
              </a>
            </li>
          
        
        
          <li class="nav-item" id="search-btn">
            <a class="nav-link" target="_self" href="javascript:;" data-toggle="modal" data-target="#modalSearch" aria-label="Search">
              <i class="iconfont icon-search"></i>
            </a>
          </li>
          
        
        
          <li class="nav-item" id="color-toggle-btn">
            <a class="nav-link" target="_self" href="javascript:;" aria-label="Color Toggle">
              <i class="iconfont icon-dark" id="color-toggle-icon"></i>
            </a>
          </li>
        
      </ul>
    </div>
  </div>
</nav>

  

<div id="banner" class="banner" parallax=true
     style="background: url('/img/default.png') no-repeat center center; background-size: cover;">
  <div class="full-bg-img">
    <div class="mask flex-center" style="background-color: rgba(0, 0, 0, 0.3)">
      <div class="banner-text text-center fade-in-up">
        <div class="h2">
          
            <span id="subtitle" data-typed-text="『C++&amp;C语言』C++课程设计，12306模拟写起来就是这么粗暴"></span>
          
        </div>

        
          
  <div class="mt-3">
    
    
      <span class="post-meta">
        <i class="iconfont icon-date-fill" aria-hidden="true"></i>
        <time datetime="2023-12-06 00:11" pubdate>
          2023年12月6日 凌晨
        </time>
      </span>
    
  </div>

  <div class="mt-1">
    
      <span class="post-meta mr-2">
        <i class="iconfont icon-chart"></i>
        
          43k 字
        
      </span>
    

    
      <span class="post-meta mr-2">
        <i class="iconfont icon-clock-fill"></i>
        
        
        
          356 分钟
        
      </span>
    

    
    
  </div>


        
      </div>

      
    </div>
  </div>
</div>

</div>

  </header>

  <main>
    
      

<div class="container-fluid nopadding-x">
  <div class="row nomargin-x">
    <div class="side-col d-none d-lg-block col-lg-2">
      

    </div>

    <div class="col-lg-8 nopadding-x-md">
      <div class="container nopadding-x-md" id="board-ctn">
        <div id="board">
          <article class="post-content mx-auto">
            <h1 id="seo-header">『C++&amp;C语言』C++课程设计，12306模拟写起来就是这么粗暴</h1>
            
            
              <div class="markdown-body">
                
                <h1 id="『C-C-语言』C-课程设计，12306-模拟写起来就是这么粗暴"><a href="#『C-C-语言』C-课程设计，12306-模拟写起来就是这么粗暴" class="headerlink" title="『C++&amp;C 语言』C++课程设计，12306 模拟写起来就是这么粗暴"></a>『C++&amp;C 语言』C++课程设计，12306 模拟写起来就是这么粗暴</h1><h4 id="这篇文章很详细，也很多希望可以好好看看！看完-C-稳过！"><a href="#这篇文章很详细，也很多希望可以好好看看！看完-C-稳过！" class="headerlink" title="这篇文章很详细，也很多希望可以好好看看！看完 C++稳过！"></a>这篇文章很详细，也很多希望可以好好看看！看完 C++稳过！</h4><p>一、12306 应该具备那些功能 1.查询（一个月以内的）： 1.查车票：出发地+目的地+出发时间-&gt;显示经过两站车票信息<br>（余票，车次信息可直接查询直接打印，是否为过路车，历时不是总历时，是两站间历时）（只有这种查询方式能查询余票） 2.车站车次查询：<br>车站+出发时间段+到达时间段-&gt;打印始发站与终点站信息（车站与时间）。<br>（查询的的车站即作为始发站，又作为终点站） 3.车次查询：车次+出发日期-&gt;打印该车次详细信息<br>（经过站点序号，站名，到时，发时，停留，终点站，起始站，历时） 2.操作 1.购票（某个区间的票-1）一天限购五张，一个月以内的。 2.退票 (某个区间的票+1) 火车开了之后，不能退票，只能改签。 3.改签（相当于退票+从新购票）一张票仅能改签一次 4.刷新 相当于重新读入 5.换乘 两个城市不能接联通，需要借助最短，需要找出中转城市，可能一个在佳木斯，一个在宜宾，这不一定是换乘一次，只要有火车站无非是换乘的次数多一点，反正能到（间隔大于 10min）。 3.管理员操作 1.增删查改站点（查）可以继承一个查询类<br>票一旦起售，不可修改站点，虽然没怎么见过火车站被拆得，但是还是有，但是拆除不可能是突然的拆除，所以会提前收到消息，先停售，再删除，修改名称可以直接修改。站点到站时间只能修改一个月以后的。 2.放票 无特殊需要，无需操作，每天的列车表都是一样的。 3.增加车次 （没有特殊要求，国家铁路局规定站点名唯一，车次名唯一） 4.用户端操作 1.各种查询 2.买退改，重点是换乘（这个不一定好写） 2.查询已买到的票<br>二、根据数据写出大体思路</p>
<ol>
<li>时间类：</li>
</ol>
<ol>
<li>数据：<br>a) 应包含年月日时分</li>
<li>函数：<br>a) 买票时间为系统时间，应该写一个自动获取函数。<br>b) 应该写一个打印时间函数<br>c) 按时间查询的时候需要获取时间，需要些 get 函数<br>d) 为了便于管理员修改信息，需要设置 set 函数<br>e) 方便输入输出重载输入输出<br>f) 需要按照时间排序，可能需要重载小于号。<br>g) 因为提前 30 天放票，所以这里要考虑写判断闰年的函数，和加减日期的函数(还有分钟的单独写，用于停靠时间，没见过一个车停靠超过一个小时的)</li>
</ol>
<ol start="2">
<li>站点数据类</li>
</ol>
<ol>
<li>数据<br>a) 站点名称 （本来想写一个 id 来着，但是中国的火车站名字唯一，自己就可以当作编号）<br>b) 经过车次（int 型 vector 的下标）写成 vector 比较合适</li>
<li>函数<br>a) 打印车次信息，理论上实可以返回一个 Vector 容器，这样就可以得到车次序号，因为在数据类中看不到列车数据。如果不行可以以引用的形式传入一个 vector 进行复制。<br>b) 重载输入输出<br>c) Set 函数 修改数据<br>d) Insert 函数 增添<br>e) Delete 函数 删除</li>
</ol>
<ol start="3">
<li>列车站台数据类<br>1） 数据<br>a） 出发时间<br>b） 到站时间<br>c） 出发时段 1-4<br>d） 到达时段 1-4<br>e） 站台伪指针（int 下标实现）<br>2） 函数<br>Get set 函数<br>加重载输入输出全家桶</li>
<li>列车类包含</li>
</ol>
<ol>
<li>数据<br>a) 车次（唯一）<br>b) 停靠站<br>到达每一个站的时间（多个列车经过相同的车站，但是时间不一定一样）。停靠站可以写一个 Vector 但是 vector 写一个 pair 类型 pair（string，pair（int，时间）），因为站名唯一，所以可以将站名用 map 映射.<br>写成一个列车站台数据类，这里用 vector 存即可。<br>c) 该车次某个站的余票<br>每个车次的每张票都是独立的这里应该写到列车类。<br>d) 每张票卖给了谁，用户的信息（存 vector，vector 的下标 1，存某个身份证，代表第一张票，关于什么靠窗，站票卧铺，每节车厢都一样，不用考虑，需要考虑吧基于某种函数关系即可算出在什么位置）。</li>
<li>函数<br>a) 买票（判断是否大于五张）<br>b) 退票( 合起来就是改签 )<br>c) 查询余票，给定区间。<br>d) 刷新<br>e) 获得用户信息，方法跟上一条站点信息一样。<br>f) 打印停靠站以及信息<br>g) 重载输入输出<br>h) 增查改站点(这个不需要条件，可以直接操作修改站名，同时修改，还有站点信息)<br>i) 删站点，改时间这些需要调整一个月以后的。<br>关于用 Vector 存火车站点的问题要调整一下。String 一般按 24 字节每辆火车按平均 20 个站点计算，中国客运火车 6000+（某度不知地道准不准），就会有 2.7MB 的火车数据文件读取，刷新一次读取这么多。而中国一共就有 5000+的火车站，四舍五入算他 1 万，用一个 usigned short 存 6 万，肯定够用，这样读取数据会快一点，所以 string 非常好也不能滥用。</li>
</ol>
<ol start="5">
<li>车票类：</li>
<li>数据：<br>a) 车票编号：基于的 hash 算法（这里保证每一张票的编号不一样即可）<br>b) 购票日期：<br>c) 车次信息：<br>d) 出发站：<br>e) 目标站：<br>f) 乘车时间：<br>只存一个月的（到时候按时间排序，超过乘车时间一个月，存成日志文件）<br>g) 购票人信息：int 指针；</li>
<li>函数<br>a) 打印车票<br>b) Get 所有的信息多个函数；<br>c) 不设置 set 函数，改签，跟退票之后 hash 值不同，直接销毁即可。<br>d) 重载输入输出<br>e) 无参初始化<br>f) 含参初始化</li>
<li>用户数据类：<br>数据<br>姓名<br>身份证号码<br>已买到的票：<br>手机号码：<br>函数<br>a) 重载输入输出<br>b) Get set 函数（仅限于手机号的修改，get 是全部）<br>c) 无参初始化<br>d) 含参初始化<br>中规中矩没有特殊操作</li>
<li>查询基类：<br>a) 车站数据<br>b) 列车数据<br>c) 用户数据<br>d) 车票数据（也是记录）<br>函数<br>a) 查车票：出发地+目的地+出发时间-&gt;显示经过两站车票信息余票，车次信息，目的地，出发地模糊查询，一个市的站都会出来。<br>能到达的车就是出发站与目的站的列车表中重合的部分<br>补充：如果不能直接到达，还需要考虑换乘，换乘实现实现的话，一开始没思路，用 BFS 的思想，用一个 queue 将初始站的所有车次的所有站点放到 queue 里，找出第一个车放到 queue 里，找到到目的地的车就储存，当第一层既出发站的所有经过地点都没有可换乘车辆时，才进行二次检索，只能换乘一次。<br>b) 车站车次查询：<br>车站+出发时间段+到达时间段-&gt;打印始发站与终点站信息（车站与时间）。<br>（查询的的车站即作为始发站，又作为终点站）<br>出发时段有四个 0-6 6-12 12-18 18-24 编号 1-4，0-24 就不做限定<br>实现直接在车站信息中调取车次数据的下标，判断即可，可以 find_if()。<br>c) 车次查询<br>打印车次详细信息，直接车站数据，find()即可。 8.用户端：<br>继承查询基类，<br>登陆：<br>查询自己的信息:<br>购票: 先查询，找到合适的车，输入传入起始站，目标站，车次，利用之前的<br>函数，配合可以完成操作。<br>退票: 从已买到的票中把票退了，数据类中以之前写了相关的函数<br>改签：先退后买。<br>换乘：&#x2F;&#x2F;把他写到了查询类里了</li>
<li>管理端：</li>
<li>增删查改站点（查）可以继承一个查询类<br>票一旦起售，不可修改站点，虽然没怎么见过火车站被拆得，但是还是有，但是拆除不可能是突然的拆除，所以会提前收到消息，先停售，再删除，修改名称可以直接修改。站点到站时间只能修改一个月以后的。 2.放票 无特殊需要，无需操作，每天的列车表都是一样的。 3.增加车次 （没有特殊要求，国家铁路局规定站点名唯一，车次名唯一）<br>能够查询所有的用户信息（按姓名，身份证号）。 4.户信息，不对用户信息进行修改。<br>5 Map 按车次 查记录</li>
<li>Map 按身份证 查记录</li>
<li>Map 按姓名（一名多人）查记录</li>
<li>按车站 查记录<br>12306 管理端能查到好几年之前的，这就得需要动态读取，文件，和动态生成文件名，目前还没有找到实现的方法，如果不行，就分成这个月，和这个月之前的。</li>
</ol>
<figure class="highlight c"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br><span class="line">48</span><br><span class="line">49</span><br><span class="line">50</span><br><span class="line">51</span><br><span class="line">52</span><br><span class="line">53</span><br><span class="line">54</span><br><span class="line">55</span><br><span class="line">56</span><br><span class="line">57</span><br><span class="line">58</span><br><span class="line">59</span><br><span class="line">60</span><br><span class="line">61</span><br><span class="line">62</span><br><span class="line">63</span><br><span class="line">64</span><br><span class="line">65</span><br><span class="line">66</span><br><span class="line">67</span><br><span class="line">68</span><br><span class="line">69</span><br><span class="line">70</span><br><span class="line">71</span><br><span class="line">72</span><br><span class="line">73</span><br><span class="line">74</span><br><span class="line">75</span><br><span class="line">76</span><br><span class="line">77</span><br><span class="line">78</span><br><span class="line">79</span><br><span class="line">80</span><br><span class="line">81</span><br><span class="line">82</span><br><span class="line">83</span><br><span class="line">84</span><br><span class="line">85</span><br><span class="line">86</span><br><span class="line">87</span><br><span class="line">88</span><br><span class="line">89</span><br><span class="line">90</span><br><span class="line">91</span><br><span class="line">92</span><br><span class="line">93</span><br><span class="line">94</span><br><span class="line">95</span><br><span class="line">96</span><br><span class="line">97</span><br><span class="line">98</span><br><span class="line">99</span><br><span class="line">100</span><br><span class="line">101</span><br><span class="line">102</span><br><span class="line">103</span><br><span class="line">104</span><br><span class="line">105</span><br><span class="line">106</span><br><span class="line">107</span><br><span class="line">108</span><br><span class="line">109</span><br><span class="line">110</span><br><span class="line">111</span><br><span class="line">112</span><br><span class="line">113</span><br><span class="line">114</span><br><span class="line">115</span><br><span class="line">116</span><br><span class="line">117</span><br><span class="line">118</span><br><span class="line">119</span><br><span class="line">120</span><br><span class="line">121</span><br><span class="line">122</span><br><span class="line">123</span><br><span class="line">124</span><br><span class="line">125</span><br><span class="line">126</span><br><span class="line">127</span><br><span class="line">128</span><br><span class="line">129</span><br><span class="line">130</span><br><span class="line">131</span><br><span class="line">132</span><br><span class="line">133</span><br><span class="line">134</span><br><span class="line">135</span><br><span class="line">136</span><br><span class="line">137</span><br><span class="line">138</span><br><span class="line">139</span><br><span class="line">140</span><br><span class="line">141</span><br><span class="line">142</span><br><span class="line">143</span><br><span class="line">144</span><br><span class="line">145</span><br><span class="line">146</span><br><span class="line">147</span><br><span class="line">148</span><br><span class="line">149</span><br><span class="line">150</span><br><span class="line">151</span><br><span class="line">152</span><br><span class="line">153</span><br><span class="line">154</span><br><span class="line">155</span><br><span class="line">156</span><br><span class="line">157</span><br><span class="line">158</span><br><span class="line">159</span><br><span class="line">160</span><br><span class="line">161</span><br><span class="line">162</span><br><span class="line">163</span><br><span class="line">164</span><br><span class="line">165</span><br><span class="line">166</span><br><span class="line">167</span><br><span class="line">168</span><br><span class="line">169</span><br><span class="line">170</span><br><span class="line">171</span><br><span class="line">172</span><br><span class="line">173</span><br><span class="line">174</span><br><span class="line">175</span><br><span class="line">176</span><br><span class="line">177</span><br><span class="line">178</span><br><span class="line">179</span><br><span class="line">180</span><br><span class="line">181</span><br><span class="line">182</span><br><span class="line">183</span><br><span class="line">184</span><br><span class="line">185</span><br><span class="line">186</span><br><span class="line">187</span><br><span class="line">188</span><br><span class="line">189</span><br><span class="line">190</span><br><span class="line">191</span><br><span class="line">192</span><br><span class="line">193</span><br><span class="line">194</span><br><span class="line">195</span><br><span class="line">196</span><br><span class="line">197</span><br><span class="line">198</span><br><span class="line">199</span><br><span class="line">200</span><br><span class="line">201</span><br><span class="line">202</span><br><span class="line">203</span><br><span class="line">204</span><br><span class="line">205</span><br><span class="line">206</span><br><span class="line">207</span><br><span class="line">208</span><br><span class="line">209</span><br><span class="line">210</span><br><span class="line">211</span><br><span class="line">212</span><br><span class="line">213</span><br><span class="line">214</span><br><span class="line">215</span><br><span class="line">216</span><br><span class="line">217</span><br><span class="line">218</span><br><span class="line">219</span><br><span class="line">220</span><br><span class="line">221</span><br><span class="line">222</span><br><span class="line">223</span><br><span class="line">224</span><br><span class="line">225</span><br><span class="line">226</span><br><span class="line">227</span><br><span class="line">228</span><br><span class="line">229</span><br><span class="line">230</span><br><span class="line">231</span><br><span class="line">232</span><br><span class="line">233</span><br><span class="line">234</span><br><span class="line">235</span><br><span class="line">236</span><br><span class="line">237</span><br><span class="line">238</span><br><span class="line">239</span><br><span class="line">240</span><br><span class="line">241</span><br><span class="line">242</span><br><span class="line">243</span><br><span class="line">244</span><br><span class="line">245</span><br><span class="line">246</span><br><span class="line">247</span><br><span class="line">248</span><br><span class="line">249</span><br><span class="line">250</span><br><span class="line">251</span><br><span class="line">252</span><br><span class="line">253</span><br><span class="line">254</span><br><span class="line">255</span><br><span class="line">256</span><br><span class="line">257</span><br><span class="line">258</span><br><span class="line">259</span><br><span class="line">260</span><br><span class="line">261</span><br><span class="line">262</span><br><span class="line">263</span><br><span class="line">264</span><br><span class="line">265</span><br><span class="line">266</span><br><span class="line">267</span><br><span class="line">268</span><br><span class="line">269</span><br><span class="line">270</span><br><span class="line">271</span><br><span class="line">272</span><br><span class="line">273</span><br><span class="line">274</span><br><span class="line">275</span><br><span class="line">276</span><br><span class="line">277</span><br><span class="line">278</span><br><span class="line">279</span><br><span class="line">280</span><br><span class="line">281</span><br><span class="line">282</span><br><span class="line">283</span><br><span class="line">284</span><br><span class="line">285</span><br><span class="line">286</span><br><span class="line">287</span><br><span class="line">288</span><br><span class="line">289</span><br><span class="line">290</span><br><span class="line">291</span><br><span class="line">292</span><br><span class="line">293</span><br><span class="line">294</span><br><span class="line">295</span><br><span class="line">296</span><br><span class="line">297</span><br><span class="line">298</span><br><span class="line">299</span><br><span class="line">300</span><br><span class="line">301</span><br><span class="line">302</span><br><span class="line">303</span><br><span class="line">304</span><br><span class="line">305</span><br><span class="line">306</span><br><span class="line">307</span><br><span class="line">308</span><br><span class="line">309</span><br><span class="line">310</span><br><span class="line">311</span><br><span class="line">312</span><br><span class="line">313</span><br><span class="line">314</span><br><span class="line">315</span><br><span class="line">316</span><br><span class="line">317</span><br><span class="line">318</span><br><span class="line">319</span><br><span class="line">320</span><br><span class="line">321</span><br><span class="line">322</span><br><span class="line">323</span><br><span class="line">324</span><br><span class="line">325</span><br><span class="line">326</span><br><span class="line">327</span><br><span class="line">328</span><br><span class="line">329</span><br><span class="line">330</span><br><span class="line">331</span><br><span class="line">332</span><br><span class="line">333</span><br><span class="line">334</span><br><span class="line">335</span><br><span class="line">336</span><br><span class="line">337</span><br><span class="line">338</span><br><span class="line">339</span><br><span class="line">340</span><br><span class="line">341</span><br><span class="line">342</span><br><span class="line">343</span><br><span class="line">344</span><br><span class="line">345</span><br><span class="line">346</span><br><span class="line">347</span><br><span class="line">348</span><br><span class="line">349</span><br><span class="line">350</span><br><span class="line">351</span><br><span class="line">352</span><br><span class="line">353</span><br><span class="line">354</span><br><span class="line">355</span><br><span class="line">356</span><br><span class="line">357</span><br><span class="line">358</span><br><span class="line">359</span><br><span class="line">360</span><br><span class="line">361</span><br><span class="line">362</span><br><span class="line">363</span><br><span class="line">364</span><br><span class="line">365</span><br><span class="line">366</span><br><span class="line">367</span><br><span class="line">368</span><br><span class="line">369</span><br><span class="line">370</span><br><span class="line">371</span><br><span class="line">372</span><br><span class="line">373</span><br><span class="line">374</span><br><span class="line">375</span><br><span class="line">376</span><br><span class="line">377</span><br><span class="line">378</span><br><span class="line">379</span><br><span class="line">380</span><br><span class="line">381</span><br><span class="line">382</span><br><span class="line">383</span><br><span class="line">384</span><br><span class="line">385</span><br><span class="line">386</span><br><span class="line">387</span><br><span class="line">388</span><br><span class="line">389</span><br><span class="line">390</span><br><span class="line">391</span><br><span class="line">392</span><br><span class="line">393</span><br><span class="line">394</span><br><span class="line">395</span><br><span class="line">396</span><br><span class="line">397</span><br><span class="line">398</span><br><span class="line">399</span><br><span class="line">400</span><br><span class="line">401</span><br><span class="line">402</span><br><span class="line">403</span><br><span class="line">404</span><br><span class="line">405</span><br><span class="line">406</span><br><span class="line">407</span><br><span class="line">408</span><br><span class="line">409</span><br><span class="line">410</span><br><span class="line">411</span><br><span class="line">412</span><br><span class="line">413</span><br><span class="line">414</span><br><span class="line">415</span><br><span class="line">416</span><br><span class="line">417</span><br><span class="line">418</span><br><span class="line">419</span><br><span class="line">420</span><br><span class="line">421</span><br><span class="line">422</span><br><span class="line">423</span><br><span class="line">424</span><br><span class="line">425</span><br><span class="line">426</span><br><span class="line">427</span><br><span class="line">428</span><br><span class="line">429</span><br><span class="line">430</span><br><span class="line">431</span><br><span class="line">432</span><br><span class="line">433</span><br><span class="line">434</span><br><span class="line">435</span><br><span class="line">436</span><br><span class="line">437</span><br><span class="line">438</span><br><span class="line">439</span><br><span class="line">440</span><br><span class="line">441</span><br><span class="line">442</span><br><span class="line">443</span><br><span class="line">444</span><br><span class="line">445</span><br><span class="line">446</span><br><span class="line">447</span><br><span class="line">448</span><br><span class="line">449</span><br><span class="line">450</span><br><span class="line">451</span><br><span class="line">452</span><br><span class="line">453</span><br><span class="line">454</span><br><span class="line">455</span><br><span class="line">456</span><br><span class="line">457</span><br><span class="line">458</span><br><span class="line">459</span><br><span class="line">460</span><br><span class="line">461</span><br><span class="line">462</span><br><span class="line">463</span><br><span class="line">464</span><br><span class="line">465</span><br><span class="line">466</span><br><span class="line">467</span><br><span class="line">468</span><br><span class="line">469</span><br><span class="line">470</span><br><span class="line">471</span><br><span class="line">472</span><br><span class="line">473</span><br><span class="line">474</span><br><span class="line">475</span><br><span class="line">476</span><br><span class="line">477</span><br><span class="line">478</span><br><span class="line">479</span><br><span class="line">480</span><br><span class="line">481</span><br><span class="line">482</span><br><span class="line">483</span><br><span class="line">484</span><br><span class="line">485</span><br><span class="line">486</span><br><span class="line">487</span><br><span class="line">488</span><br><span class="line">489</span><br><span class="line">490</span><br><span class="line">491</span><br><span class="line">492</span><br><span class="line">493</span><br><span class="line">494</span><br><span class="line">495</span><br><span class="line">496</span><br><span class="line">497</span><br><span class="line">498</span><br><span class="line">499</span><br><span class="line">500</span><br><span class="line">501</span><br><span class="line">502</span><br><span class="line">503</span><br><span class="line">504</span><br><span class="line">505</span><br><span class="line">506</span><br><span class="line">507</span><br><span class="line">508</span><br><span class="line">509</span><br><span class="line">510</span><br><span class="line">511</span><br><span class="line">512</span><br><span class="line">513</span><br><span class="line">514</span><br><span class="line">515</span><br><span class="line">516</span><br><span class="line">517</span><br><span class="line">518</span><br><span class="line">519</span><br><span class="line">520</span><br><span class="line">521</span><br><span class="line">522</span><br><span class="line">523</span><br><span class="line">524</span><br><span class="line">525</span><br><span class="line">526</span><br><span class="line">527</span><br><span class="line">528</span><br><span class="line">529</span><br><span class="line">530</span><br><span class="line">531</span><br><span class="line">532</span><br><span class="line">533</span><br><span class="line">534</span><br><span class="line">535</span><br><span class="line">536</span><br><span class="line">537</span><br><span class="line">538</span><br><span class="line">539</span><br><span class="line">540</span><br><span class="line">541</span><br><span class="line">542</span><br><span class="line">543</span><br><span class="line">544</span><br><span class="line">545</span><br><span class="line">546</span><br><span class="line">547</span><br><span class="line">548</span><br><span class="line">549</span><br><span class="line">550</span><br><span class="line">551</span><br><span class="line">552</span><br><span class="line">553</span><br><span class="line">554</span><br><span class="line">555</span><br><span class="line">556</span><br><span class="line">557</span><br><span class="line">558</span><br><span class="line">559</span><br><span class="line">560</span><br><span class="line">561</span><br><span class="line">562</span><br><span class="line">563</span><br><span class="line">564</span><br><span class="line">565</span><br><span class="line">566</span><br><span class="line">567</span><br><span class="line">568</span><br><span class="line">569</span><br><span class="line">570</span><br><span class="line">571</span><br><span class="line">572</span><br><span class="line">573</span><br><span class="line">574</span><br><span class="line">575</span><br><span class="line">576</span><br><span class="line">577</span><br><span class="line">578</span><br><span class="line">579</span><br><span class="line">580</span><br><span class="line">581</span><br><span class="line">582</span><br><span class="line">583</span><br><span class="line">584</span><br><span class="line">585</span><br><span class="line">586</span><br><span class="line">587</span><br><span class="line">588</span><br><span class="line">589</span><br><span class="line">590</span><br><span class="line">591</span><br><span class="line">592</span><br><span class="line">593</span><br><span class="line">594</span><br><span class="line">595</span><br><span class="line">596</span><br><span class="line">597</span><br><span class="line">598</span><br><span class="line">599</span><br><span class="line">600</span><br><span class="line">601</span><br><span class="line">602</span><br><span class="line">603</span><br><span class="line">604</span><br><span class="line">605</span><br><span class="line">606</span><br><span class="line">607</span><br><span class="line">608</span><br><span class="line">609</span><br><span class="line">610</span><br><span class="line">611</span><br><span class="line">612</span><br><span class="line">613</span><br><span class="line">614</span><br><span class="line">615</span><br><span class="line">616</span><br><span class="line">617</span><br><span class="line">618</span><br><span class="line">619</span><br><span class="line">620</span><br><span class="line">621</span><br><span class="line">622</span><br><span class="line">623</span><br><span class="line">624</span><br><span class="line">625</span><br><span class="line">626</span><br><span class="line">627</span><br><span class="line">628</span><br><span class="line">629</span><br><span class="line">630</span><br><span class="line">631</span><br><span class="line">632</span><br><span class="line">633</span><br><span class="line">634</span><br><span class="line">635</span><br><span class="line">636</span><br><span class="line">637</span><br><span class="line">638</span><br><span class="line">639</span><br><span class="line">640</span><br><span class="line">641</span><br><span class="line">642</span><br><span class="line">643</span><br><span class="line">644</span><br><span class="line">645</span><br><span class="line">646</span><br><span class="line">647</span><br><span class="line">648</span><br><span class="line">649</span><br><span class="line">650</span><br><span class="line">651</span><br><span class="line">652</span><br><span class="line">653</span><br><span class="line">654</span><br><span class="line">655</span><br><span class="line">656</span><br><span class="line">657</span><br><span class="line">658</span><br><span class="line">659</span><br><span class="line">660</span><br><span class="line">661</span><br><span class="line">662</span><br><span class="line">663</span><br><span class="line">664</span><br><span class="line">665</span><br><span class="line">666</span><br><span class="line">667</span><br><span class="line">668</span><br><span class="line">669</span><br><span class="line">670</span><br><span class="line">671</span><br><span class="line">672</span><br><span class="line">673</span><br><span class="line">674</span><br><span class="line">675</span><br><span class="line">676</span><br><span class="line">677</span><br><span class="line">678</span><br><span class="line">679</span><br><span class="line">680</span><br><span class="line">681</span><br><span class="line">682</span><br><span class="line">683</span><br><span class="line">684</span><br><span class="line">685</span><br><span class="line">686</span><br><span class="line">687</span><br><span class="line">688</span><br><span class="line">689</span><br><span class="line">690</span><br><span class="line">691</span><br><span class="line">692</span><br><span class="line">693</span><br><span class="line">694</span><br><span class="line">695</span><br><span class="line">696</span><br><span class="line">697</span><br><span class="line">698</span><br><span class="line">699</span><br><span class="line">700</span><br><span class="line">701</span><br><span class="line">702</span><br><span class="line">703</span><br><span class="line">704</span><br><span class="line">705</span><br><span class="line">706</span><br><span class="line">707</span><br><span class="line">708</span><br><span class="line">709</span><br><span class="line">710</span><br><span class="line">711</span><br><span class="line">712</span><br><span class="line">713</span><br><span class="line">714</span><br><span class="line">715</span><br><span class="line">716</span><br><span class="line">717</span><br><span class="line">718</span><br><span class="line">719</span><br><span class="line">720</span><br><span class="line">721</span><br><span class="line">722</span><br><span class="line">723</span><br><span class="line">724</span><br><span class="line">725</span><br><span class="line">726</span><br><span class="line">727</span><br><span class="line">728</span><br><span class="line">729</span><br><span class="line">730</span><br><span class="line">731</span><br><span class="line">732</span><br><span class="line">733</span><br><span class="line">734</span><br><span class="line">735</span><br><span class="line">736</span><br><span class="line">737</span><br><span class="line">738</span><br><span class="line">739</span><br><span class="line">740</span><br><span class="line">741</span><br><span class="line">742</span><br><span class="line">743</span><br><span class="line">744</span><br><span class="line">745</span><br><span class="line">746</span><br><span class="line">747</span><br><span class="line">748</span><br><span class="line">749</span><br><span class="line">750</span><br><span class="line">751</span><br><span class="line">752</span><br><span class="line">753</span><br><span class="line">754</span><br><span class="line">755</span><br><span class="line">756</span><br><span class="line">757</span><br><span class="line">758</span><br><span class="line">759</span><br><span class="line">760</span><br><span class="line">761</span><br><span class="line">762</span><br><span class="line">763</span><br><span class="line">764</span><br><span class="line">765</span><br><span class="line">766</span><br><span class="line">767</span><br><span class="line">768</span><br><span class="line">769</span><br><span class="line">770</span><br><span class="line">771</span><br><span class="line">772</span><br><span class="line">773</span><br><span class="line">774</span><br><span class="line">775</span><br><span class="line">776</span><br><span class="line">777</span><br><span class="line">778</span><br><span class="line">779</span><br><span class="line">780</span><br><span class="line">781</span><br><span class="line">782</span><br><span class="line">783</span><br><span class="line">784</span><br><span class="line">785</span><br><span class="line">786</span><br><span class="line">787</span><br><span class="line">788</span><br><span class="line">789</span><br><span class="line">790</span><br><span class="line">791</span><br><span class="line">792</span><br><span class="line">793</span><br><span class="line">794</span><br><span class="line">795</span><br><span class="line">796</span><br><span class="line">797</span><br><span class="line">798</span><br><span class="line">799</span><br><span class="line">800</span><br><span class="line">801</span><br><span class="line">802</span><br><span class="line">803</span><br><span class="line">804</span><br><span class="line">805</span><br><span class="line">806</span><br><span class="line">807</span><br><span class="line">808</span><br><span class="line">809</span><br><span class="line">810</span><br><span class="line">811</span><br><span class="line">812</span><br><span class="line">813</span><br><span class="line">814</span><br><span class="line">815</span><br><span class="line">816</span><br><span class="line">817</span><br><span class="line">818</span><br><span class="line">819</span><br><span class="line">820</span><br><span class="line">821</span><br><span class="line">822</span><br><span class="line">823</span><br><span class="line">824</span><br><span class="line">825</span><br><span class="line">826</span><br><span class="line">827</span><br><span class="line">828</span><br><span class="line">829</span><br><span class="line">830</span><br><span class="line">831</span><br><span class="line">832</span><br><span class="line">833</span><br><span class="line">834</span><br><span class="line">835</span><br><span class="line">836</span><br><span class="line">837</span><br><span class="line">838</span><br><span class="line">839</span><br><span class="line">840</span><br><span class="line">841</span><br><span class="line">842</span><br><span class="line">843</span><br><span class="line">844</span><br><span class="line">845</span><br><span class="line">846</span><br><span class="line">847</span><br><span class="line">848</span><br><span class="line">849</span><br><span class="line">850</span><br><span class="line">851</span><br><span class="line">852</span><br><span class="line">853</span><br><span class="line">854</span><br><span class="line">855</span><br><span class="line">856</span><br><span class="line">857</span><br><span class="line">858</span><br><span class="line">859</span><br><span class="line">860</span><br><span class="line">861</span><br><span class="line">862</span><br><span class="line">863</span><br><span class="line">864</span><br><span class="line">865</span><br><span class="line">866</span><br><span class="line">867</span><br><span class="line">868</span><br><span class="line">869</span><br><span class="line">870</span><br><span class="line">871</span><br><span class="line">872</span><br><span class="line">873</span><br><span class="line">874</span><br><span class="line">875</span><br><span class="line">876</span><br><span class="line">877</span><br><span class="line">878</span><br><span class="line">879</span><br><span class="line">880</span><br><span class="line">881</span><br><span class="line">882</span><br><span class="line">883</span><br><span class="line">884</span><br><span class="line">885</span><br><span class="line">886</span><br><span class="line">887</span><br><span class="line">888</span><br><span class="line">889</span><br><span class="line">890</span><br><span class="line">891</span><br><span class="line">892</span><br><span class="line">893</span><br><span class="line">894</span><br><span class="line">895</span><br><span class="line">896</span><br><span class="line">897</span><br><span class="line">898</span><br><span class="line">899</span><br><span class="line">900</span><br><span class="line">901</span><br><span class="line">902</span><br><span class="line">903</span><br><span class="line">904</span><br><span class="line">905</span><br><span class="line">906</span><br><span class="line">907</span><br><span class="line">908</span><br><span class="line">909</span><br><span class="line">910</span><br><span class="line">911</span><br><span class="line">912</span><br><span class="line">913</span><br><span class="line">914</span><br><span class="line">915</span><br><span class="line">916</span><br><span class="line">917</span><br><span class="line">918</span><br><span class="line">919</span><br><span class="line">920</span><br><span class="line">921</span><br><span class="line">922</span><br><span class="line">923</span><br><span class="line">924</span><br><span class="line">925</span><br><span class="line">926</span><br><span class="line">927</span><br><span class="line">928</span><br><span class="line">929</span><br><span class="line">930</span><br><span class="line">931</span><br><span class="line">932</span><br><span class="line">933</span><br><span class="line">934</span><br><span class="line">935</span><br><span class="line">936</span><br><span class="line">937</span><br><span class="line">938</span><br><span class="line">939</span><br><span class="line">940</span><br><span class="line">941</span><br><span class="line">942</span><br><span class="line">943</span><br><span class="line">944</span><br><span class="line">945</span><br><span class="line">946</span><br><span class="line">947</span><br><span class="line">948</span><br><span class="line">949</span><br><span class="line">950</span><br><span class="line">951</span><br><span class="line">952</span><br><span class="line">953</span><br><span class="line">954</span><br><span class="line">955</span><br><span class="line">956</span><br><span class="line">957</span><br><span class="line">958</span><br><span class="line">959</span><br><span class="line">960</span><br><span class="line">961</span><br><span class="line">962</span><br><span class="line">963</span><br><span class="line">964</span><br><span class="line">965</span><br><span class="line">966</span><br><span class="line">967</span><br><span class="line">968</span><br><span class="line">969</span><br><span class="line">970</span><br><span class="line">971</span><br><span class="line">972</span><br><span class="line">973</span><br><span class="line">974</span><br><span class="line">975</span><br><span class="line">976</span><br><span class="line">977</span><br><span class="line">978</span><br><span class="line">979</span><br><span class="line">980</span><br><span class="line">981</span><br><span class="line">982</span><br><span class="line">983</span><br><span class="line">984</span><br><span class="line">985</span><br><span class="line">986</span><br><span class="line">987</span><br><span class="line">988</span><br><span class="line">989</span><br><span class="line">990</span><br><span class="line">991</span><br><span class="line">992</span><br><span class="line">993</span><br><span class="line">994</span><br><span class="line">995</span><br><span class="line">996</span><br><span class="line">997</span><br><span class="line">998</span><br><span class="line">999</span><br><span class="line">1000</span><br><span class="line">1001</span><br><span class="line">1002</span><br><span class="line">1003</span><br><span class="line">1004</span><br><span class="line">1005</span><br><span class="line">1006</span><br><span class="line">1007</span><br><span class="line">1008</span><br><span class="line">1009</span><br><span class="line">1010</span><br><span class="line">1011</span><br><span class="line">1012</span><br><span class="line">1013</span><br><span class="line">1014</span><br><span class="line">1015</span><br><span class="line">1016</span><br><span class="line">1017</span><br><span class="line">1018</span><br><span class="line">1019</span><br><span class="line">1020</span><br><span class="line">1021</span><br><span class="line">1022</span><br><span class="line">1023</span><br><span class="line">1024</span><br><span class="line">1025</span><br><span class="line">1026</span><br><span class="line">1027</span><br><span class="line">1028</span><br><span class="line">1029</span><br><span class="line">1030</span><br><span class="line">1031</span><br><span class="line">1032</span><br><span class="line">1033</span><br><span class="line">1034</span><br><span class="line">1035</span><br><span class="line">1036</span><br><span class="line">1037</span><br><span class="line">1038</span><br><span class="line">1039</span><br><span class="line">1040</span><br><span class="line">1041</span><br><span class="line">1042</span><br><span class="line">1043</span><br><span class="line">1044</span><br><span class="line">1045</span><br><span class="line">1046</span><br><span class="line">1047</span><br><span class="line">1048</span><br><span class="line">1049</span><br><span class="line">1050</span><br><span class="line">1051</span><br><span class="line">1052</span><br><span class="line">1053</span><br><span class="line">1054</span><br><span class="line">1055</span><br><span class="line">1056</span><br><span class="line">1057</span><br><span class="line">1058</span><br><span class="line">1059</span><br><span class="line">1060</span><br><span class="line">1061</span><br><span class="line">1062</span><br><span class="line">1063</span><br><span class="line">1064</span><br><span class="line">1065</span><br><span class="line">1066</span><br><span class="line">1067</span><br><span class="line">1068</span><br><span class="line">1069</span><br><span class="line">1070</span><br><span class="line">1071</span><br><span class="line">1072</span><br><span class="line">1073</span><br><span class="line">1074</span><br><span class="line">1075</span><br><span class="line">1076</span><br><span class="line">1077</span><br><span class="line">1078</span><br><span class="line">1079</span><br><span class="line">1080</span><br><span class="line">1081</span><br><span class="line">1082</span><br><span class="line">1083</span><br><span class="line">1084</span><br><span class="line">1085</span><br><span class="line">1086</span><br><span class="line">1087</span><br><span class="line">1088</span><br><span class="line">1089</span><br><span class="line">1090</span><br><span class="line">1091</span><br><span class="line">1092</span><br><span class="line">1093</span><br><span class="line">1094</span><br><span class="line">1095</span><br><span class="line">1096</span><br><span class="line">1097</span><br><span class="line">1098</span><br><span class="line">1099</span><br><span class="line">1100</span><br><span class="line">1101</span><br><span class="line">1102</span><br><span class="line">1103</span><br><span class="line">1104</span><br><span class="line">1105</span><br><span class="line">1106</span><br><span class="line">1107</span><br><span class="line">1108</span><br><span class="line">1109</span><br><span class="line">1110</span><br><span class="line">1111</span><br><span class="line">1112</span><br><span class="line">1113</span><br><span class="line">1114</span><br><span class="line">1115</span><br><span class="line">1116</span><br><span class="line">1117</span><br><span class="line">1118</span><br><span class="line">1119</span><br><span class="line">1120</span><br><span class="line">1121</span><br><span class="line">1122</span><br><span class="line">1123</span><br><span class="line">1124</span><br><span class="line">1125</span><br><span class="line">1126</span><br><span class="line">1127</span><br><span class="line">1128</span><br><span class="line">1129</span><br><span class="line">1130</span><br><span class="line">1131</span><br><span class="line">1132</span><br><span class="line">1133</span><br><span class="line">1134</span><br><span class="line">1135</span><br><span class="line">1136</span><br><span class="line">1137</span><br><span class="line">1138</span><br><span class="line">1139</span><br><span class="line">1140</span><br><span class="line">1141</span><br><span class="line">1142</span><br><span class="line">1143</span><br><span class="line">1144</span><br><span class="line">1145</span><br><span class="line">1146</span><br><span class="line">1147</span><br><span class="line">1148</span><br><span class="line">1149</span><br><span class="line">1150</span><br><span class="line">1151</span><br><span class="line">1152</span><br><span class="line">1153</span><br><span class="line">1154</span><br><span class="line">1155</span><br><span class="line">1156</span><br><span class="line">1157</span><br><span class="line">1158</span><br><span class="line">1159</span><br><span class="line">1160</span><br><span class="line">1161</span><br><span class="line">1162</span><br><span class="line">1163</span><br><span class="line">1164</span><br><span class="line">1165</span><br><span class="line">1166</span><br><span class="line">1167</span><br><span class="line">1168</span><br><span class="line">1169</span><br><span class="line">1170</span><br><span class="line">1171</span><br><span class="line">1172</span><br><span class="line">1173</span><br><span class="line">1174</span><br><span class="line">1175</span><br><span class="line">1176</span><br><span class="line">1177</span><br><span class="line">1178</span><br><span class="line">1179</span><br><span class="line">1180</span><br><span class="line">1181</span><br><span class="line">1182</span><br><span class="line">1183</span><br><span class="line">1184</span><br><span class="line">1185</span><br><span class="line">1186</span><br><span class="line">1187</span><br><span class="line">1188</span><br><span class="line">1189</span><br><span class="line">1190</span><br><span class="line">1191</span><br><span class="line">1192</span><br><span class="line">1193</span><br><span class="line">1194</span><br><span class="line">1195</span><br><span class="line">1196</span><br><span class="line">1197</span><br><span class="line">1198</span><br><span class="line">1199</span><br><span class="line">1200</span><br><span class="line">1201</span><br><span class="line">1202</span><br><span class="line">1203</span><br><span class="line">1204</span><br><span class="line">1205</span><br><span class="line">1206</span><br><span class="line">1207</span><br><span class="line">1208</span><br><span class="line">1209</span><br><span class="line">1210</span><br><span class="line">1211</span><br><span class="line">1212</span><br><span class="line">1213</span><br><span class="line">1214</span><br><span class="line">1215</span><br><span class="line">1216</span><br><span class="line">1217</span><br><span class="line">1218</span><br><span class="line">1219</span><br><span class="line">1220</span><br><span class="line">1221</span><br><span class="line">1222</span><br><span class="line">1223</span><br><span class="line">1224</span><br><span class="line">1225</span><br><span class="line">1226</span><br><span class="line">1227</span><br><span class="line">1228</span><br><span class="line">1229</span><br><span class="line">1230</span><br><span class="line">1231</span><br><span class="line">1232</span><br><span class="line">1233</span><br><span class="line">1234</span><br><span class="line">1235</span><br><span class="line">1236</span><br><span class="line">1237</span><br><span class="line">1238</span><br><span class="line">1239</span><br><span class="line">1240</span><br><span class="line">1241</span><br><span class="line">1242</span><br><span class="line">1243</span><br><span class="line">1244</span><br><span class="line">1245</span><br><span class="line">1246</span><br><span class="line">1247</span><br><span class="line">1248</span><br><span class="line">1249</span><br><span class="line">1250</span><br><span class="line">1251</span><br><span class="line">1252</span><br><span class="line">1253</span><br><span class="line">1254</span><br><span class="line">1255</span><br><span class="line">1256</span><br><span class="line">1257</span><br><span class="line">1258</span><br><span class="line">1259</span><br><span class="line">1260</span><br><span class="line">1261</span><br><span class="line">1262</span><br><span class="line">1263</span><br><span class="line">1264</span><br><span class="line">1265</span><br><span class="line">1266</span><br><span class="line">1267</span><br><span class="line">1268</span><br><span class="line">1269</span><br><span class="line">1270</span><br><span class="line">1271</span><br><span class="line">1272</span><br><span class="line">1273</span><br><span class="line">1274</span><br><span class="line">1275</span><br><span class="line">1276</span><br><span class="line">1277</span><br><span class="line">1278</span><br><span class="line">1279</span><br><span class="line">1280</span><br><span class="line">1281</span><br><span class="line">1282</span><br><span class="line">1283</span><br><span class="line">1284</span><br><span class="line">1285</span><br><span class="line">1286</span><br><span class="line">1287</span><br><span class="line">1288</span><br><span class="line">1289</span><br><span class="line">1290</span><br><span class="line">1291</span><br><span class="line">1292</span><br><span class="line">1293</span><br><span class="line">1294</span><br><span class="line">1295</span><br><span class="line">1296</span><br><span class="line">1297</span><br><span class="line">1298</span><br><span class="line">1299</span><br><span class="line">1300</span><br><span class="line">1301</span><br><span class="line">1302</span><br><span class="line">1303</span><br><span class="line">1304</span><br><span class="line">1305</span><br><span class="line">1306</span><br><span class="line">1307</span><br><span class="line">1308</span><br><span class="line">1309</span><br><span class="line">1310</span><br><span class="line">1311</span><br><span class="line">1312</span><br><span class="line">1313</span><br><span class="line">1314</span><br><span class="line">1315</span><br><span class="line">1316</span><br><span class="line">1317</span><br><span class="line">1318</span><br><span class="line">1319</span><br><span class="line">1320</span><br><span class="line">1321</span><br><span class="line">1322</span><br><span class="line">1323</span><br><span class="line">1324</span><br><span class="line">1325</span><br><span class="line">1326</span><br><span class="line">1327</span><br><span class="line">1328</span><br><span class="line">1329</span><br><span class="line">1330</span><br><span class="line">1331</span><br><span class="line">1332</span><br><span class="line">1333</span><br><span class="line">1334</span><br><span class="line">1335</span><br><span class="line">1336</span><br><span class="line">1337</span><br><span class="line">1338</span><br><span class="line">1339</span><br><span class="line">1340</span><br><span class="line">1341</span><br><span class="line">1342</span><br><span class="line">1343</span><br><span class="line">1344</span><br><span class="line">1345</span><br><span class="line">1346</span><br><span class="line">1347</span><br><span class="line">1348</span><br><span class="line">1349</span><br><span class="line">1350</span><br><span class="line">1351</span><br><span class="line">1352</span><br><span class="line">1353</span><br><span class="line">1354</span><br><span class="line">1355</span><br><span class="line">1356</span><br><span class="line">1357</span><br><span class="line">1358</span><br><span class="line">1359</span><br><span class="line">1360</span><br><span class="line">1361</span><br><span class="line">1362</span><br><span class="line">1363</span><br><span class="line">1364</span><br><span class="line">1365</span><br><span class="line">1366</span><br><span class="line">1367</span><br><span class="line">1368</span><br><span class="line">1369</span><br><span class="line">1370</span><br><span class="line">1371</span><br><span class="line">1372</span><br><span class="line">1373</span><br><span class="line">1374</span><br><span class="line">1375</span><br><span class="line">1376</span><br><span class="line">1377</span><br><span class="line">1378</span><br><span class="line">1379</span><br><span class="line">1380</span><br><span class="line">1381</span><br><span class="line">1382</span><br><span class="line">1383</span><br><span class="line">1384</span><br><span class="line">1385</span><br><span class="line">1386</span><br><span class="line">1387</span><br><span class="line">1388</span><br><span class="line">1389</span><br><span class="line">1390</span><br><span class="line">1391</span><br><span class="line">1392</span><br><span class="line">1393</span><br><span class="line">1394</span><br><span class="line">1395</span><br><span class="line">1396</span><br><span class="line">1397</span><br><span class="line">1398</span><br><span class="line">1399</span><br><span class="line">1400</span><br><span class="line">1401</span><br><span class="line">1402</span><br><span class="line">1403</span><br><span class="line">1404</span><br><span class="line">1405</span><br><span class="line">1406</span><br><span class="line">1407</span><br><span class="line">1408</span><br><span class="line">1409</span><br><span class="line">1410</span><br><span class="line">1411</span><br><span class="line">1412</span><br><span class="line">1413</span><br><span class="line">1414</span><br><span class="line">1415</span><br><span class="line">1416</span><br><span class="line">1417</span><br><span class="line">1418</span><br><span class="line">1419</span><br><span class="line">1420</span><br><span class="line">1421</span><br><span class="line">1422</span><br><span class="line">1423</span><br><span class="line">1424</span><br><span class="line">1425</span><br><span class="line">1426</span><br><span class="line">1427</span><br><span class="line">1428</span><br><span class="line">1429</span><br><span class="line">1430</span><br><span class="line">1431</span><br><span class="line">1432</span><br><span class="line">1433</span><br><span class="line">1434</span><br><span class="line">1435</span><br><span class="line">1436</span><br><span class="line">1437</span><br><span class="line">1438</span><br><span class="line">1439</span><br><span class="line">1440</span><br><span class="line">1441</span><br><span class="line">1442</span><br><span class="line">1443</span><br><span class="line">1444</span><br><span class="line">1445</span><br><span class="line">1446</span><br><span class="line">1447</span><br><span class="line">1448</span><br><span class="line">1449</span><br><span class="line">1450</span><br><span class="line">1451</span><br><span class="line">1452</span><br><span class="line">1453</span><br><span class="line">1454</span><br><span class="line">1455</span><br><span class="line">1456</span><br><span class="line">1457</span><br><span class="line">1458</span><br><span class="line">1459</span><br><span class="line">1460</span><br><span class="line">1461</span><br><span class="line">1462</span><br><span class="line">1463</span><br><span class="line">1464</span><br><span class="line">1465</span><br><span class="line">1466</span><br><span class="line">1467</span><br><span class="line">1468</span><br><span class="line">1469</span><br><span class="line">1470</span><br><span class="line">1471</span><br><span class="line">1472</span><br><span class="line">1473</span><br><span class="line">1474</span><br><span class="line">1475</span><br><span class="line">1476</span><br><span class="line">1477</span><br><span class="line">1478</span><br><span class="line">1479</span><br><span class="line">1480</span><br><span class="line">1481</span><br><span class="line">1482</span><br><span class="line">1483</span><br><span class="line">1484</span><br><span class="line">1485</span><br><span class="line">1486</span><br><span class="line">1487</span><br><span class="line">1488</span><br><span class="line">1489</span><br><span class="line">1490</span><br><span class="line">1491</span><br><span class="line">1492</span><br><span class="line">1493</span><br><span class="line">1494</span><br><span class="line">1495</span><br><span class="line">1496</span><br><span class="line">1497</span><br><span class="line">1498</span><br><span class="line">1499</span><br><span class="line">1500</span><br><span class="line">1501</span><br><span class="line">1502</span><br><span class="line">1503</span><br><span class="line">1504</span><br><span class="line">1505</span><br><span class="line">1506</span><br><span class="line">1507</span><br><span class="line">1508</span><br><span class="line">1509</span><br><span class="line">1510</span><br><span class="line">1511</span><br><span class="line">1512</span><br><span class="line">1513</span><br><span class="line">1514</span><br><span class="line">1515</span><br><span class="line">1516</span><br><span class="line">1517</span><br><span class="line">1518</span><br><span class="line">1519</span><br><span class="line">1520</span><br><span class="line">1521</span><br><span class="line">1522</span><br><span class="line">1523</span><br><span class="line">1524</span><br><span class="line">1525</span><br><span class="line">1526</span><br><span class="line">1527</span><br><span class="line">1528</span><br><span class="line">1529</span><br><span class="line">1530</span><br><span class="line">1531</span><br><span class="line">1532</span><br><span class="line">1533</span><br><span class="line">1534</span><br><span class="line">1535</span><br><span class="line">1536</span><br><span class="line">1537</span><br><span class="line">1538</span><br><span class="line">1539</span><br><span class="line">1540</span><br><span class="line">1541</span><br><span class="line">1542</span><br><span class="line">1543</span><br><span class="line">1544</span><br><span class="line">1545</span><br><span class="line">1546</span><br><span class="line">1547</span><br><span class="line">1548</span><br><span class="line">1549</span><br><span class="line">1550</span><br><span class="line">1551</span><br><span class="line">1552</span><br><span class="line">1553</span><br><span class="line">1554</span><br><span class="line">1555</span><br><span class="line">1556</span><br><span class="line">1557</span><br><span class="line">1558</span><br><span class="line">1559</span><br><span class="line">1560</span><br><span class="line">1561</span><br><span class="line">1562</span><br><span class="line">1563</span><br></pre></td><td class="code"><pre><code class="hljs c"><span class="hljs-meta">#<span class="hljs-keyword">include</span><span class="hljs-string">&lt;bits/stdc++.h.&gt;</span></span><br>using namespace <span class="hljs-built_in">std</span>;<br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Time</span></span><br><span class="hljs-class">&#123;</span><br>    <span class="hljs-type">int</span>  year,month,day;<br>    <span class="hljs-type">int</span> hour,mini;<br>public:<br>    Time()&#123;loadtime();&#125;<br>    Time(<span class="hljs-type">int</span> y,<span class="hljs-type">int</span> m,<span class="hljs-type">int</span> d):year(y),month(m),day(d)&#123;&#125;;   <span class="hljs-comment">//用于车票生成。</span><br>    <span class="hljs-type">void</span> <span class="hljs-title function_">loadtime</span><span class="hljs-params">()</span>;    <span class="hljs-comment">//定义时间获取函数，用于获取买票时间，直接从系统读入；</span><br>    friend istream &amp; operator&gt;&gt;(istream &amp;in,Time &amp; a);<br>    friend <span class="hljs-built_in">stringstream</span> &amp; operator&gt;&gt;(<span class="hljs-built_in">stringstream</span> &amp;in,Time &amp; a);<br>    friend ostream &amp; operator&lt;&lt;(ostream &amp;out,Time &amp; a); <span class="hljs-comment">//排序函数，用于车票信息的储存；</span><br>    <span class="hljs-type">bool</span> operator &lt;(<span class="hljs-type">const</span> Time &amp;d)<span class="hljs-type">const</span>;   <span class="hljs-comment">//重载小于号，用于数据时间排序，不需要修改数据const</span><br>    <span class="hljs-type">int</span> <span class="hljs-title function_">judge</span><span class="hljs-params">()</span> <span class="hljs-type">const</span>;  <span class="hljs-comment">//判断是否为闰年;</span><br>    <span class="hljs-type">int</span> <span class="hljs-title function_">judge</span><span class="hljs-params">(<span class="hljs-type">int</span> year)</span> <span class="hljs-type">const</span> ;<span class="hljs-comment">//写一个有参的判断函数；</span><br>    Time operator +(<span class="hljs-type">int</span>  a) ;   <span class="hljs-comment">//重载加号,用于放票；</span><br>     <span class="hljs-type">bool</span> operator ==(Time &amp; a) ; <span class="hljs-comment">//判断是否为一天；</span><br>    friend <span class="hljs-type">int</span> operator -(Time a,Time b);  <span class="hljs-comment">//计算两段时间间隔；</span><br>    <span class="hljs-type">void</span> <span class="hljs-title function_">print</span><span class="hljs-params">()</span><span class="hljs-type">const</span>;<span class="hljs-comment">//打印时间；</span><br>    <span class="hljs-type">bool</span> operator&gt;(Time&amp;a);<br>    <span class="hljs-type">int</span> <span class="hljs-title function_">getday</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> day;&#125;<br>    <span class="hljs-type">int</span> <span class="hljs-title function_">getmonth</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> month;&#125;<br>    <span class="hljs-type">int</span> <span class="hljs-title function_">getyear</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> year;&#125;<br>    <span class="hljs-type">int</span> <span class="hljs-title function_">gethour</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> hour;&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">set</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setmonth</span><span class="hljs-params">(<span class="hljs-type">int</span> a)</span>&#123;month=a;&#125;<br>    <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt; <span class="hljs-title function_">tksj</span><span class="hljs-params">(Time&amp;b)</span>; <span class="hljs-comment">//停靠时间</span><br>    <span class="hljs-type">void</span> <span class="hljs-title function_">seth</span><span class="hljs-params">(<span class="hljs-type">int</span> a,<span class="hljs-type">int</span> b)</span>&#123;hour=a;mini=b;&#125;<br>&#125;;<br> <span class="hljs-type">bool</span> Time ::operator&gt;(Time&amp;a)<br> &#123;<br>      <span class="hljs-keyword">return</span> (year!=a.year)?year&gt;a.year:month!=a.month?month&gt;a.month:day!=a.day?day&gt;a.day:<span class="hljs-number">0</span>;<br> &#125;<br><span class="hljs-type">bool</span> Time::operator ==(Time &amp; a)<br>&#123;<br>    <span class="hljs-keyword">return</span> (year!=a.year)?<span class="hljs-number">0</span>:month!=a.month?<span class="hljs-number">0</span>:day!=a.day?<span class="hljs-number">0</span>:hour!=a.hour?<span class="hljs-number">0</span>:mini==a.mini;<br>&#125;<br>Time Time::operator +(<span class="hljs-type">int</span>  a)<br>&#123;<br>    <span class="hljs-type">int</span> m[] = &#123;<span class="hljs-number">0</span>,<span class="hljs-number">31</span>,<span class="hljs-number">28</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>&#125;;<br>    day+=a;<br>    <span class="hljs-type">int</span> flag=<span class="hljs-number">1</span>;<br>   <span class="hljs-keyword">while</span>(day&gt;m[month])&#123;<br>        <span class="hljs-keyword">if</span>(month==<span class="hljs-number">2</span>)&#123;<br>            <span class="hljs-keyword">if</span>(day&gt;m[month]+judge())&#123;<br>                day-=m[month]+judge();<br>                month++;<br>            &#125;<br>        &#125;<br>        <span class="hljs-keyword">else</span> &#123;<br>            day=day-m[month];<br>            month++;<br>        &#125;<br>        <span class="hljs-keyword">if</span>(month&gt;<span class="hljs-number">12</span>)&#123;<br>        month-=<span class="hljs-number">12</span>;<br>        year++;<br>    &#125;<br>   &#125;<br>&#125;<br><span class="hljs-type">int</span> operator -(Time a,Time b)<br>&#123;<br>    <span class="hljs-type">int</span> monthdays[<span class="hljs-number">2</span>][<span class="hljs-number">12</span>] = &#123; &#123; <span class="hljs-number">31</span>,<span class="hljs-number">28</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span> &#125;,&#123; <span class="hljs-number">31</span>,<span class="hljs-number">29</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span> &#125; &#125;;<br>    <span class="hljs-type">int</span> yeardays[<span class="hljs-number">2</span>] = &#123; <span class="hljs-number">365</span>,<span class="hljs-number">366</span> &#125;;<br>    <span class="hljs-type">int</span> sumdays=<span class="hljs-number">0</span>;<br>   <span class="hljs-keyword">if</span> (a.year == b.year&amp;&amp; a.month == b.month)&#123;<br>        sumdays = b.day - a.day;<br>    &#125;<br>    <span class="hljs-keyword">else</span><br>        <span class="hljs-keyword">if</span> (a.year == b.year)&#123;<br>            sumdays += monthdays[a.judge(a.year)][a.month<span class="hljs-number">-1</span>] - a.day;<br>            <span class="hljs-keyword">for</span> (<span class="hljs-type">int</span> i = a.month; i &lt; b.month<span class="hljs-number">-1</span>; i++)<br>                sumdays += monthdays[a.judge(a.year)][i];<br>            sumdays += b.day;<br>        &#125;<br>        <span class="hljs-keyword">else</span>&#123;<br>            sumdays += monthdays[a.judge(a.year)][a.month<span class="hljs-number">-1</span>] - a.day;<br>            <span class="hljs-keyword">for</span> (<span class="hljs-type">int</span> i = a.month; i &lt; <span class="hljs-number">12</span>; i++)<br>                sumdays += monthdays[a.judge(a.year)][i];<br>            <span class="hljs-keyword">for</span> (<span class="hljs-type">int</span> i = a.year + <span class="hljs-number">1</span>; i &lt; b.year; i++)<br>                sumdays += yeardays[a.judge(i)];<br>            <span class="hljs-keyword">for</span> (<span class="hljs-type">int</span> i = <span class="hljs-number">0</span>; i &lt; b.month - <span class="hljs-number">1</span>; i++)<br>                sumdays += monthdays[a.judge(b.year)][i];<br>            sumdays += b.day;<br>        &#125;<br>    <span class="hljs-keyword">return</span> sumdays;<br>&#125;<br><span class="hljs-type">int</span> <span class="hljs-title function_">Time::judge</span><span class="hljs-params">()</span> <span class="hljs-type">const</span>&#123;<br>        <span class="hljs-keyword">if</span>(year % <span class="hljs-number">4</span> == <span class="hljs-number">0</span> &amp;&amp; year %<span class="hljs-number">100</span> != <span class="hljs-number">0</span> ||year % <span class="hljs-number">400</span> == <span class="hljs-number">0</span>) <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>        <span class="hljs-keyword">else</span> <span class="hljs-keyword">return</span> <span class="hljs-number">0</span>;<br>&#125;<br><span class="hljs-type">int</span> <span class="hljs-title function_">Time::judge</span><span class="hljs-params">(<span class="hljs-type">int</span> year)</span> <span class="hljs-type">const</span>&#123;<br>    <span class="hljs-keyword">if</span> (year % <span class="hljs-number">4</span> == <span class="hljs-number">0</span> &amp;&amp; year % <span class="hljs-number">100</span> != <span class="hljs-number">0</span> || year % <span class="hljs-number">400</span> == <span class="hljs-number">0</span>)<span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>    <span class="hljs-keyword">else</span>  <span class="hljs-keyword">return</span> <span class="hljs-number">0</span>;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Time::loadtime</span><span class="hljs-params">()</span>&#123;<br>    <span class="hljs-type">time_t</span> rawtime;<br>    <span class="hljs-class"><span class="hljs-keyword">struct</span> <span class="hljs-title">tm</span> *<span class="hljs-title">ptminfo</span>;</span><br>    time(&amp;rawtime);<br>    ptminfo = localtime(&amp;rawtime);<br>    year=ptminfo-&gt;tm_year + <span class="hljs-number">1900</span>;<br>    month=ptminfo-&gt;tm_mon + <span class="hljs-number">1</span>;<br>    day=ptminfo-&gt;tm_mday;<br>    hour=ptminfo-&gt;tm_hour;<br>    mini=ptminfo-&gt;tm_min;<br>&#125;<br>istream &amp; operator&gt;&gt;(istream &amp;in,Time &amp; a)&#123;<br>    in&gt;&gt;a.year&gt;&gt;a.month&gt;&gt;a.day&gt;&gt;a.hour&gt;&gt;a.mini;<br>    <span class="hljs-keyword">return</span> in;<br>&#125;<br>ostream &amp; operator&lt;&lt;(ostream &amp;out,Time &amp; a)<br>&#123;<br>    out&lt;&lt;a.year&lt;&lt;<span class="hljs-string">&quot; &quot;</span>&lt;&lt;a.month&lt;&lt;<span class="hljs-string">&quot; &quot;</span>&lt;&lt;a.day&lt;&lt;<span class="hljs-string">&quot; &quot;</span>&lt;&lt;a.hour&lt;&lt;<span class="hljs-string">&quot; &quot;</span>&lt;&lt;a.mini&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>    <span class="hljs-keyword">return</span> out;<br>&#125;<br><span class="hljs-built_in">stringstream</span> &amp; operator&gt;&gt;(<span class="hljs-built_in">stringstream</span> &amp;in,Time &amp; a)&#123;<br>    in&gt;&gt;a.year&gt;&gt;a.month&gt;&gt;a.day&gt;&gt;a.hour&gt;&gt;a.mini;<br>    <span class="hljs-keyword">return</span> in;<br>&#125;<br><span class="hljs-type">bool</span> Time:: operator &lt;(<span class="hljs-type">const</span> Time &amp;d)<span class="hljs-type">const</span>&#123;<br>    <span class="hljs-keyword">return</span> year!=d.year?year&lt;d.year:month!=d.month?month&lt;d.month:day!=d.day?hour&lt;d.hour:mini&lt;d.mini;<br>&#125;<br><span class="hljs-type">void</span> Time:: print()<span class="hljs-type">const</span><br>&#123;<br>      <span class="hljs-built_in">cout</span>&lt;&lt;year&lt;&lt;<span class="hljs-string">&quot;年&quot;</span>&lt;&lt;month&lt;&lt;<span class="hljs-string">&quot;月&quot;</span>&lt;&lt;day&lt;&lt;<span class="hljs-string">&quot;日&quot;</span>;<br>            <span class="hljs-built_in">printf</span>(<span class="hljs-string">&quot;%02d:%02d\n&quot;</span>,hour,mini);<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Time::set</span><span class="hljs-params">()</span><span class="hljs-comment">//容错处理</span><br>&#123;<br>        <span class="hljs-type">int</span> monthdays[<span class="hljs-number">2</span>][<span class="hljs-number">12</span>] = &#123; &#123; <span class="hljs-number">31</span>,<span class="hljs-number">28</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span> &#125;,&#123; <span class="hljs-number">31</span>,<span class="hljs-number">29</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span>,<span class="hljs-number">30</span>,<span class="hljs-number">31</span> &#125; &#125;;<br>      <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;请依次输入&quot;</span>&lt;&lt;<span class="hljs-string">&quot; 年&quot;</span>&lt;&lt;<span class="hljs-string">&quot; 月&quot;</span>&lt;&lt;<span class="hljs-string">&quot; 日&quot;</span>&lt;&lt;<span class="hljs-string">&quot; 小时&quot;</span>&lt;&lt;<span class="hljs-string">&quot; 分钟&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>      <span class="hljs-built_in">cin</span>&gt;&gt;year;<br>      <span class="hljs-keyword">while</span>(year&lt;<span class="hljs-number">2019</span>)&#123;<span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;不是正确时间，请重新输入年&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<span class="hljs-built_in">cin</span>&gt;&gt;year;&#125;<br>     <span class="hljs-built_in">cin</span> &gt;&gt;month;<br>      <span class="hljs-keyword">while</span>(month&gt;<span class="hljs-number">12</span>||month&lt;<span class="hljs-number">1</span>)&#123;<span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;不是正确时间，请重新输入月&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<span class="hljs-built_in">cin</span>&gt;&gt;month;&#125;<br>     <span class="hljs-built_in">cin</span>&gt;&gt;day;<br>      <span class="hljs-keyword">while</span>(monthdays[judge()][month<span class="hljs-number">-1</span>]&lt;day||day&lt;<span class="hljs-number">1</span>)&#123;<span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;不是正确时间，请重新输入日&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<span class="hljs-built_in">cin</span>&gt;&gt;day;&#125;<br>    <span class="hljs-built_in">cin</span>&gt;&gt;hour;<br>    <span class="hljs-keyword">while</span>(hour&gt;<span class="hljs-number">24</span>||hour&lt;<span class="hljs-number">0</span>)&#123;<span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;不是正确时间，请重新输入小时&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<span class="hljs-built_in">cin</span>&gt;&gt;hour;&#125;<br>    <span class="hljs-built_in">cin</span>&gt;&gt;mini;<br>    <span class="hljs-keyword">while</span>(mini&gt;<span class="hljs-number">60</span>||mini&lt;<span class="hljs-number">0</span>)&#123;<span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;不是正确时间，请重新输入分钟&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<span class="hljs-built_in">cin</span>&gt;&gt;mini;&#125;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;时间已更改为&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    print();<br>&#125;<br><span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt; <span class="hljs-title function_">Time::tksj</span><span class="hljs-params">(Time &amp;b)</span><span class="hljs-comment">//高铁晚上不开车，不考虑超过一天；</span><br>&#123;<br>    <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt;  w;<br>    <span class="hljs-keyword">if</span>(mini&lt;b.mini)<br>    &#123;<br>       w.second=mini-b.mini+<span class="hljs-number">60</span>;<br>       w.first=hour-b.hour<span class="hljs-number">-1</span>;<br>       <span class="hljs-keyword">return</span> w;<br>    &#125;<br>    w.second=mini-b.mini;<br>    w.first=hour-b.hour;<br>    <span class="hljs-keyword">return</span> w;<br>&#125;<br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Time demo;</span><br><span class="hljs-comment">    demo.loadtime();</span><br><span class="hljs-comment">    cout&lt;&lt;demo&lt;&lt;endl;</span><br><span class="hljs-comment">    demo.print();</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Time demo1;</span><br><span class="hljs-comment">    cin&gt;&gt;demo1;</span><br><span class="hljs-comment">    Time demo2(demo1);</span><br><span class="hljs-comment">    demo1.print();</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Time demo;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.judge()&lt;&lt;endl;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.judge(2008)&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    set&lt;Time&gt;demo;</span><br><span class="hljs-comment">    Time tx;</span><br><span class="hljs-comment">    int     n=3;</span><br><span class="hljs-comment">    while(n--)</span><br><span class="hljs-comment">    &#123;</span><br><span class="hljs-comment">        tx.set();</span><br><span class="hljs-comment">        demo.insert(tx);</span><br><span class="hljs-comment">    &#125;</span><br><span class="hljs-comment">     set&lt;Time&gt;::iterator po;</span><br><span class="hljs-comment">    for(po=demo.begin();po!=demo.end();po++)  (*po).print();</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Time demo1,demo2;</span><br><span class="hljs-comment">    demo1.loadtime();</span><br><span class="hljs-comment">    cin&gt;&gt;demo2;</span><br><span class="hljs-comment">    cout&lt;&lt;demo2.tksj(demo1).first&lt;&lt;&#x27; &#x27;&lt;&lt;demo2.tksj(demo1).second;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-class"><span class="hljs-keyword">struct</span> <span class="hljs-title">piao</span></span><br><span class="hljs-class">&#123;</span><br>    <span class="hljs-built_in">string</span> name;<br>    <span class="hljs-type">int</span> sum[<span class="hljs-number">31</span>];<br>    <span class="hljs-type">bool</span> operator &lt;(<span class="hljs-type">const</span> piao&amp; a)<span class="hljs-type">const</span><br>    &#123;<br>        <span class="hljs-keyword">return</span> name&lt;a.name;<br>    &#125;<br>&#125;;<br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Station</span></span><br><span class="hljs-class">&#123;</span><br>    <span class="hljs-built_in">string</span> name; <span class="hljs-comment">//车站名唯一</span><br>    <span class="hljs-type">int</span> crotrain;<span class="hljs-comment">//经过车次数量</span><br>    <span class="hljs-built_in">vector</span>&lt;piao&gt; checi; <span class="hljs-comment">//第一个string是车次，第二个是余票</span><br>    <span class="hljs-comment">//这个车站最多买多少张票，不一定跟总票数相同</span><br>public:<br>    Station(<span class="hljs-built_in">string</span> na,<span class="hljs-type">int</span> n);<br>    Station():name(<span class="hljs-string">&quot;&quot;</span>),crotrain(<span class="hljs-number">0</span>)&#123;checi.clear();&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">print</span><span class="hljs-params">(<span class="hljs-type">int</span> riqi)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">insert</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<span class="hljs-comment">//为站台增加车次</span><br>    <span class="hljs-built_in">vector</span>&lt;piao&gt;&amp; <span class="hljs-title function_">quecheci</span><span class="hljs-params">()</span>;<br>    friend istream&amp;   operator&gt;&gt;(istream &amp;in,Station &amp; a);<br>    friend   ostream&amp;   operator&lt;&lt;(ostream &amp;out,Station &amp; a);<br>    <span class="hljs-type">bool</span> <span class="hljs-title function_">del</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>    <span class="hljs-type">bool</span> <span class="hljs-title function_">set</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-type">int</span> b,<span class="hljs-type">int</span> c)</span>;<span class="hljs-comment">// 如果需要调度余票，可以修改</span><br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setname</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>&#123;this-&gt;name=a;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getname</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> name;&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">buytic</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-type">int</span> b)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">rebac</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-type">int</span> b)</span>;<br>&#125;;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Station::rebac</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-type">int</span> b)</span><br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=checi.begin();po!=checi.end();po++)<br>        <span class="hljs-keyword">if</span>(po-&gt;name==a) po-&gt;sum[b]++;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Station::buytic</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-type">int</span> b)</span><br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=checi.begin();po!=checi.end();po++)<br>        <span class="hljs-keyword">if</span>(po-&gt;name==a) po-&gt;sum[b]--;<br>&#125;<br>Station::Station(<span class="hljs-built_in">string</span> na,<span class="hljs-type">int</span> n)<br>&#123;<br>    name=na;<br>    crotrain=n;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-type">int</span> i=<span class="hljs-number">0</span>;i&lt;n;i++)<br>    &#123;<br>       <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;输入车次 余票：\n&quot;</span>;<br>        piao w;<br>        <span class="hljs-built_in">cin</span>&gt;&gt;w.name;<br>        <span class="hljs-keyword">for</span>(<span class="hljs-type">int</span> i=<span class="hljs-number">0</span>;i&lt;<span class="hljs-number">31</span>;i++) <span class="hljs-built_in">cin</span>&gt;&gt;w.sum[i];<br>      checi.push_back(w);<br>    &#125;<br>&#125;<br>istream&amp; operator&gt;&gt;(istream&amp; in,Station &amp; w)<br>&#123;<br>    in&gt;&gt;w.name&gt;&gt;w.crotrain;<br>    <span class="hljs-comment">//cout&lt;&lt;w.crotrain&lt;&lt;endl;</span><br>    <span class="hljs-keyword">for</span>(<span class="hljs-type">int</span> i=<span class="hljs-number">0</span>;i&lt;w.crotrain;i++)<br>    &#123;<br>        piao qq;<br>        in&gt;&gt;qq.name;<br>        <span class="hljs-keyword">for</span>(<span class="hljs-type">int</span> i=<span class="hljs-number">0</span>;i&lt;<span class="hljs-number">31</span>;i++) in&gt;&gt;qq.sum[i];<br>     w.checi.push_back(qq);<br>    &#125;<br>    <span class="hljs-keyword">return</span> in;<br>&#125;<br>ostream&amp; operator&lt;&lt;(ostream&amp; out,Station &amp; w)<br>&#123;<br>    out&lt;&lt;w.name&lt;&lt;<span class="hljs-string">&quot; &quot;</span>&lt;&lt;w.crotrain&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=w.checi.begin();po!=w.checi.end();po++)<br>    &#123;<br>        out&lt;&lt;po-&gt;name&lt;&lt;<span class="hljs-built_in">endl</span>;<br>        <span class="hljs-keyword">for</span>(<span class="hljs-type">int</span> i=<span class="hljs-number">0</span>;i&lt;<span class="hljs-number">31</span>;i++)  out&lt;&lt;po-&gt;sum[i]&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>        out&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    &#125;<br>    <span class="hljs-keyword">return</span> out;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Station::print</span><span class="hljs-params">(<span class="hljs-type">int</span> b)</span><br>&#123;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;name&lt;&lt;<span class="hljs-string">&quot;:&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=checi.begin();po!=checi.end();po++)<br>    &#123;<br>        <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;车次:&quot;</span>&lt;&lt;po-&gt;name&lt;&lt;<span class="hljs-string">&quot; 余票:&quot;</span>&lt;&lt;po-&gt;sum[b]&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    &#125;<br>&#125;<br><span class="hljs-built_in">vector</span>&lt;piao&gt;&amp; Station ::quecheci()<br>&#123;<br>    <span class="hljs-keyword">return</span> checi;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Station::insert</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span><br>&#123;<br>        piao w;<br>        w.name=a;<br>        <span class="hljs-keyword">for</span>(<span class="hljs-type">int</span> i=<span class="hljs-number">0</span>;i&lt;<span class="hljs-number">31</span>;i++) <span class="hljs-built_in">cin</span>&gt;&gt;w.sum[i];<br>      checi.push_back(w);<br>&#125;<br><span class="hljs-type">bool</span> <span class="hljs-title function_">Station::del</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span><br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=checi.begin();po!=checi.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(po-&gt;name==a) &#123;checi.erase(po);<span class="hljs-keyword">break</span>;&#125;<br>    &#125;<br>    <span class="hljs-keyword">if</span>(checi.size()!=crotrain)<br>    &#123;<br>        crotrain=checi.size();<br>        <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>    &#125;<br>    <span class="hljs-keyword">else</span>  <span class="hljs-keyword">return</span> <span class="hljs-number">0</span>;<br>&#125;<br>  <span class="hljs-type">bool</span> <span class="hljs-title function_">Station::set</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-type">int</span> b,<span class="hljs-type">int</span> c)</span><br>  &#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=checi.begin();po!=checi.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(po-&gt;name==a) &#123;<br>            po-&gt;sum[c]=b;<br>            <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>        &#125;<br>        <span class="hljs-keyword">else</span> <span class="hljs-keyword">return</span> <span class="hljs-number">0</span>;<br>    &#125;<br>  &#125;<br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    int n;</span><br><span class="hljs-comment">    string a;</span><br><span class="hljs-comment">    cin&gt;&gt;n&gt;&gt;a;</span><br><span class="hljs-comment">    Station demo(a,n) ;</span><br><span class="hljs-comment">    demo.print();</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Station demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    cout&lt;&lt;demo;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Station demo;</span><br><span class="hljs-comment">    int a;</span><br><span class="hljs-comment">    string b;</span><br><span class="hljs-comment">    cin&gt;&gt;b&gt;&gt;a;</span><br><span class="hljs-comment">    demo.insert(b,a);</span><br><span class="hljs-comment">    cin&gt;&gt;b&gt;&gt;a;</span><br><span class="hljs-comment">    demo.insert(b,a);</span><br><span class="hljs-comment">    vector&lt;pair&lt;string,int&gt;&gt;w=demo.quecheci();</span><br><span class="hljs-comment">    for(auto po=w.begin();po!=w.end();po++)</span><br><span class="hljs-comment">        cout&lt;&lt;po-&gt;first&lt;&lt;&#x27; &#x27;&lt;&lt;po-&gt;second&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Station demo;</span><br><span class="hljs-comment">    string a;</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.setname(a);</span><br><span class="hljs-comment">    int b;</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b;</span><br><span class="hljs-comment">    demo.insert(a,b);</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b;</span><br><span class="hljs-comment">    demo.insert(a,b);</span><br><span class="hljs-comment">    demo.print();</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.del(a)&lt;&lt;endl;</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.del(a);</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.set(a,b)&lt;&lt;endl;</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.set(a,b)&lt;&lt;endl;</span><br><span class="hljs-comment">    demo.print();</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">//修改后从新测试，get/set比较比较简单，一般不会写错。</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Station demo;</span><br><span class="hljs-comment">    string b;</span><br><span class="hljs-comment">    cin&gt;&gt;b;</span><br><span class="hljs-comment">    demo.insert(b);</span><br><span class="hljs-comment">    cin&gt;&gt;b;</span><br><span class="hljs-comment">    demo.insert(b);</span><br><span class="hljs-comment">    vector&lt;piao&gt;w=demo.quecheci();</span><br><span class="hljs-comment">    for(auto po=w.begin();po!=w.end();po++)</span><br><span class="hljs-comment">       &#123;</span><br><span class="hljs-comment">            cout&lt;&lt;po-&gt;name&lt;&lt;&#x27; &#x27;;</span><br><span class="hljs-comment">            for(int i=0;i&lt;31;i++) cout&lt;&lt;po-&gt;sum[i]&lt;&lt;&#x27; &#x27;;</span><br><span class="hljs-comment">            cout&lt;&lt;endl;</span><br><span class="hljs-comment">       &#125;</span><br><span class="hljs-comment"></span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Zt</span>  //中规中矩的全家桶数据类</span><br><span class="hljs-class">&#123;</span><br>    <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt; arrive; <span class="hljs-comment">//在某站的出发到达时家间；</span><br>    <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt; leave;<br>    <span class="hljs-built_in">string</span>  station;  <span class="hljs-comment">//作为数据类时指向vector站台;</span><br>    <span class="hljs-type">int</span> piao[<span class="hljs-number">31</span>];<span class="hljs-comment">// 实际上存在多少票,今天五号，五号前的是下个月，五号后是这个月，不能买今天前的票。</span><br>public:<br>    Zt(<span class="hljs-built_in">string</span>  a,<span class="hljs-type">int</span> c,<span class="hljs-type">int</span> d,<span class="hljs-type">int</span> e,<span class="hljs-type">int</span> f):station(a)&#123;setarrive(c,d);setleave(e,f);fill(piao,piao+<span class="hljs-number">31</span>,<span class="hljs-number">100</span>);&#125;<br>    Zt()&#123;fill(piao,piao+<span class="hljs-number">31</span>,<span class="hljs-number">100</span>);&#125;<br>     <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt;  &amp;<span class="hljs-title function_">getarrive</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> arrive;&#125;<br>     <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt;  &amp;<span class="hljs-title function_">getleave</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> leave;&#125;<br>    <span class="hljs-type">int</span> <span class="hljs-title function_">getarr</span><span class="hljs-params">()</span>; <span class="hljs-comment">//出发时段到达只是时段</span><br>    <span class="hljs-type">int</span> <span class="hljs-title function_">getlea</span><span class="hljs-params">()</span>;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getsta</span><span class="hljs-params">()</span><span class="hljs-type">const</span>&#123;<span class="hljs-keyword">return</span> station;&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setarrive</span><span class="hljs-params">(<span class="hljs-type">int</span> a,<span class="hljs-type">int</span> b)</span>&#123;arrive.first=a;arrive.second=b;&#125;  <span class="hljs-comment">//用于修改出站到站时间；</span><br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setleave</span><span class="hljs-params">(<span class="hljs-type">int</span> a,<span class="hljs-type">int</span> b)</span>&#123;leave.first=a;leave.second=b;&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setsta</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span>&#123;station=a;&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">printtk</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">print</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">printa</span><span class="hljs-params">()</span>;<br>     <span class="hljs-type">void</span> <span class="hljs-title function_">printl</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">int</span> <span class="hljs-title function_">getpiao</span><span class="hljs-params">(<span class="hljs-type">int</span> i)</span>&#123;<span class="hljs-keyword">return</span> piao[i];&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setpiao</span><span class="hljs-params">(<span class="hljs-type">int</span> a,<span class="hljs-type">int</span> b)</span>&#123;piao[b]=a;&#125;<br>    friend istream&amp;operator&gt;&gt;(istream &amp;in,Zt&amp; a);<br>    friend ostream&amp;operator&lt;&lt;(ostream &amp;out,Zt&amp; a);<br>&#125;;<br><span class="hljs-type">void</span> Zt:: print()<br>&#123;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;station&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-built_in">printf</span>(<span class="hljs-string">&quot;%02d:%02d &quot;</span>,arrive.first,arrive.second);<br>    <span class="hljs-comment">//cout&lt;&lt;arrive.first&lt;&lt;arrive.second&lt;&lt;endl;</span><br>    <span class="hljs-built_in">printf</span>(<span class="hljs-string">&quot;%02d:%02d\n&quot;</span>,leave.first,leave.second);<br>   <span class="hljs-comment">// cout&lt;&lt;leave.first&lt;&lt;leave.second&lt;&lt;endl;</span><br>&#125;<br><span class="hljs-type">void</span> Zt:: printl()<br>&#123;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;station&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-built_in">printf</span>(<span class="hljs-string">&quot;%02d:%02d\n&quot;</span>,leave.first,leave.second);<br>&#125;<br><span class="hljs-type">void</span> Zt:: printa()<br>&#123;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;station&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-built_in">printf</span>(<span class="hljs-string">&quot;%02d:%02d &quot;</span>,arrive.first,arrive.second);<br>&#125;<br><span class="hljs-type">int</span> <span class="hljs-title function_">Zt::getarr</span><span class="hljs-params">()</span><br>&#123;<br>    <span class="hljs-keyword">if</span>(arrive.first&gt;=<span class="hljs-number">0</span>||arrive.first&lt;<span class="hljs-number">6</span>) <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>    <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span>(arrive.first&gt;=<span class="hljs-number">6</span>||arrive.first&lt;<span class="hljs-number">12</span>) <span class="hljs-keyword">return</span> <span class="hljs-number">2</span>;<br>    <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span>(arrive.first&gt;=<span class="hljs-number">12</span>||arrive.first&lt;<span class="hljs-number">18</span>) <span class="hljs-keyword">return</span> <span class="hljs-number">3</span>;<br>    <span class="hljs-keyword">else</span> <span class="hljs-keyword">return</span> <span class="hljs-number">4</span>;<br>&#125;<br><span class="hljs-type">int</span> <span class="hljs-title function_">Zt::getlea</span><span class="hljs-params">()</span><br>&#123;<br>    <span class="hljs-keyword">if</span>(leave.first&gt;=<span class="hljs-number">0</span>||leave.first&lt;<span class="hljs-number">6</span>) <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>    <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span>(leave.first&gt;=<span class="hljs-number">6</span>||leave.first&lt;<span class="hljs-number">12</span>) <span class="hljs-keyword">return</span> <span class="hljs-number">2</span>;<br>    <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span>(leave.first&gt;=<span class="hljs-number">12</span>||leave.first&lt;<span class="hljs-number">18</span>) <span class="hljs-keyword">return</span> <span class="hljs-number">3</span>;<br>    <span class="hljs-keyword">else</span> <span class="hljs-keyword">return</span> <span class="hljs-number">4</span>;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Zt::printtk</span><span class="hljs-params">()</span><br>&#123;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;leave.second-arrive.second&lt;&lt;<span class="hljs-string">&quot;分钟 &quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<span class="hljs-comment">//没有超过一个小时的；</span><br>&#125;<br>istream&amp;operator&gt;&gt;(istream &amp;in,Zt&amp; a)<br>&#123;<br>    in&gt;&gt;a.station;<br>   <span class="hljs-comment">// cout&lt;&lt;a.station;</span><br>   in&gt;&gt;a.arrive.first;<br> <span class="hljs-comment">//  cout&lt;&lt;a.station;</span><br>    in&gt;&gt;a.arrive.second;<br><span class="hljs-comment">//    cout&lt;&lt;a.station;</span><br>    in&gt;&gt;a.leave.first;<br> <span class="hljs-comment">//   cout&lt;&lt;a.station;</span><br>    in&gt;&gt;a.leave.second;<br>    <span class="hljs-comment">//cout&lt;&lt;a.station;</span><br>    <span class="hljs-keyword">for</span>(<span class="hljs-type">int</span> i=<span class="hljs-number">0</span>;i&lt;<span class="hljs-number">31</span>;i++) in&gt;&gt;a.piao[i];<br>    <span class="hljs-keyword">return</span> in;<br>&#125;<br>ostream&amp;operator&lt;&lt;(ostream &amp;out,Zt &amp;a)<br>&#123;<br>    out&lt;&lt;a.station&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.arrive.first&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.arrive.second&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.leave.first&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.leave.second&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-type">int</span> i=<span class="hljs-number">0</span>;i&lt;<span class="hljs-number">31</span>;i++) out&lt;&lt;a.piao[i]&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>    out&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">return</span> out;<br>&#125;<br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment"></span><br><span class="hljs-comment">    string a;</span><br><span class="hljs-comment">    int b,c,d,e;</span><br><span class="hljs-comment">     Zt demo(a,b,c,d,e);</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getpiao(15)&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Zt demo1;</span><br><span class="hljs-comment">    vector&lt;Zt&gt;demo;</span><br><span class="hljs-comment">    while(cin&gt;&gt;demo1) demo.push_back(demo1);</span><br><span class="hljs-comment">    cout&lt;&lt;demo1;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    short n;</span><br><span class="hljs-comment">    cin&gt;&gt;n;</span><br><span class="hljs-comment">    Zt demo(n);</span><br><span class="hljs-comment">    demo.print();</span><br><span class="hljs-comment">    demo.printtk();</span><br><span class="hljs-comment">   cout&lt;&lt;demo.getlea()&lt;&lt;endl;</span><br><span class="hljs-comment">   cout&lt;&lt;demo.getarr()&lt;&lt;endl;</span><br><span class="hljs-comment">   cout&lt;&lt;demo.getsta()&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Zt demo;</span><br><span class="hljs-comment">   demo.setarrive();</span><br><span class="hljs-comment">   demo.setleave();</span><br><span class="hljs-comment">   cout&lt;&lt;demo.getarrive()&lt;&lt;endl;</span><br><span class="hljs-comment">   cout&lt;&lt;demo.getleave()&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Zt demo;</span><br><span class="hljs-comment">    int n;</span><br><span class="hljs-comment">    cin&gt;&gt;n;</span><br><span class="hljs-comment">    demo.setpiao(n);</span><br><span class="hljs-comment">    cout&lt;&lt; demo.getpiao();</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Train</span></span><br><span class="hljs-class">&#123;</span><br>    <span class="hljs-built_in">string</span> train; <span class="hljs-comment">//车次</span><br>    <span class="hljs-built_in">vector</span>&lt;Zt&gt; station;<br>    <span class="hljs-built_in">vector</span>&lt;<span class="hljs-built_in">string</span>&gt;people;<span class="hljs-comment">//谁买了票指向peo下标，居题买那张票，再等用户的数据,或者存身份证。</span><br>                <span class="hljs-comment">//双重map，不如直接string</span><br>    <span class="hljs-built_in">map</span>&lt;<span class="hljs-built_in">string</span>,<span class="hljs-type">int</span>&gt; ys;<br>    <span class="hljs-class"><span class="hljs-keyword">struct</span> <span class="hljs-title">node</span></span><br><span class="hljs-class">    &#123;</span><br>        <span class="hljs-type">int</span> val;<br>        <span class="hljs-type">int</span> len;<br>        <span class="hljs-type">int</span> lazy;<br>        <span class="hljs-type">int</span> l,r;<br>    &#125;tree[<span class="hljs-number">31</span>][<span class="hljs-number">300005</span>];<br>public:<br><br>    Train():train(<span class="hljs-string">&quot;&quot;</span>)&#123;people.clear();station.clear();&#125;<br>    Train(<span class="hljs-built_in">string</span> tr):train (tr)&#123;people.clear();station.clear();&#125;<br>    <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt; <span class="hljs-title function_">buytic</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a,<span class="hljs-built_in">string</span>  b,<span class="hljs-type">int</span> riqi)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">reback</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a,<span class="hljs-built_in">string</span>  b,<span class="hljs-type">int</span> riqi)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">insert</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a,<span class="hljs-type">int</span> d,<span class="hljs-type">int</span> f,<span class="hljs-type">int</span> g,<span class="hljs-type">int</span> h,<span class="hljs-built_in">string</span> w)</span>;<br>    <span class="hljs-type">bool</span> <span class="hljs-title function_">del</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">cx</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>; <span class="hljs-comment">//查到就打印，查不到就拉倒</span><br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setarrive</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span>;<span class="hljs-comment">//修改某个站的到站时间出发时间</span><br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setleave</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setsta</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>    <span class="hljs-type">int</span> <span class="hljs-title function_">cxyp</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a, <span class="hljs-built_in">string</span> b,<span class="hljs-type">int</span> c)</span>;<br>    <span class="hljs-built_in">vector</span>&lt;<span class="hljs-built_in">string</span>&gt;&amp;<span class="hljs-title function_">getpeople</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> people;&#125;<br>   <span class="hljs-comment">// void printf();无法获取站台信息，只能传引用了</span><br>     <span class="hljs-built_in">vector</span>&lt;Zt&gt;&amp; <span class="hljs-title function_">getzt</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> station;&#125;<br>     friend istream&amp;operator&gt;&gt;(istream&amp; in,Train &amp;a);<br>     friend ostream&amp;operator&lt;&lt;(ostream&amp; out,Train &amp;a);<br>     <span class="hljs-type">void</span> <span class="hljs-title function_">settr</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>&#123;train=a;&#125;<br>     <span class="hljs-built_in">string</span>  <span class="hljs-title function_">gettr</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> train;&#125;<br>     <span class="hljs-comment">//void built_tree( int node, int left, int right,int day );</span><br>  <span class="hljs-comment">//  void  pushdown(int root,int day)  ;//向下传递lazy标记</span><br>  <span class="hljs-comment">//  int query(int root,int l,int r,int day);  //计算区间和</span><br>  <span class="hljs-comment">//  void  update(int root,int l,int r,int addval,int day);  //区间更新</span><br>&#125;;<br><span class="hljs-comment">/*void Train:: built_tree(int root,int l,int r,int day)  //建树</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    int mid;</span><br><span class="hljs-comment">    tree[day][root].lazy=0;</span><br><span class="hljs-comment">    tree[day][root].l=l;</span><br><span class="hljs-comment">    tree[day][root].r=r;</span><br><span class="hljs-comment">    tree[day][root].len=r-l+1;</span><br><span class="hljs-comment">    if (l==r) tree[day][root].val=station[l].getpiao(day);</span><br><span class="hljs-comment">    else</span><br><span class="hljs-comment">    &#123;</span><br><span class="hljs-comment">        mid=(l+r)/2;</span><br><span class="hljs-comment">        built_tree(root*2,l,mid,day);</span><br><span class="hljs-comment">        built_tree(root*2+1,mid+1,r,day);</span><br><span class="hljs-comment">        tree[day][root].val=min(tree[day][root*2].val,tree[day][root*2+1].val);</span><br><span class="hljs-comment">    &#125;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*void Train:: pushdown(int root,int day)  //向下传递lazy标记</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    if (tree[day][root].lazy)</span><br><span class="hljs-comment">    &#123;</span><br><span class="hljs-comment">        tree[day][root*2].lazy+=tree[day][root].lazy;</span><br><span class="hljs-comment">        tree[day][root*2+1].lazy+=tree[day][root].lazy;</span><br><span class="hljs-comment">        tree[day][root*2].val+=tree[day][root].lazy;</span><br><span class="hljs-comment">        tree[day][root*2+1].val+=tree[day][root].lazy;</span><br><span class="hljs-comment">        tree[day][root].lazy=0;</span><br><span class="hljs-comment">    &#125;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">int Train:: query(int root,int l,int r,int day)  //计算区间和</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    int mid;</span><br><span class="hljs-comment">    if (tree[day][root].l&gt;=l&amp;&amp;tree[day][root].r&lt;=r)</span><br><span class="hljs-comment">        return tree[day][root].val;</span><br><span class="hljs-comment">    if (tree[day][root].l&gt;r||tree[day][root].r&lt;l)</span><br><span class="hljs-comment">        return 0x7f7f7f7f;</span><br><span class="hljs-comment">    if (tree[day][root].lazy) pushdown(root,day);</span><br><span class="hljs-comment">    return min(query(root*2,l,r,day),query(root*2+1,l,r,day));</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">void Train:: update(int root,int l,int r,int addval,int day)  //区间更新</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    int mid;</span><br><span class="hljs-comment">    if (tree[day][root].l&gt;=l&amp;&amp;tree[day][root].r&lt;=r)</span><br><span class="hljs-comment">    &#123;</span><br><span class="hljs-comment">        tree[day][root].lazy+=addval;</span><br><span class="hljs-comment">        tree[day][root].val+=addval;</span><br><span class="hljs-comment">        return;</span><br><span class="hljs-comment">    &#125;</span><br><span class="hljs-comment">    if (tree[day][root].l&gt;r||tree[day][root].r&lt;l)</span><br><span class="hljs-comment">        return;</span><br><span class="hljs-comment">    if (tree[day][root].lazy) pushdown(root,day);</span><br><span class="hljs-comment">    update(root*2,l,r,addval,day);</span><br><span class="hljs-comment">    update(root*2+1,l,r,addval,day);</span><br><span class="hljs-comment">    tree[day][root].val=min(tree[day][root*2].val,tree[day][root*2+1].val);</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt;  <span class="hljs-title function_">Train::buytic</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a,<span class="hljs-built_in">string</span>  b,<span class="hljs-type">int</span> c)</span>  <span class="hljs-comment">//站台的票和列车票是分步的 ,这是买票操作的一部分。</span><br>&#123;<br>    <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt; www;<br> <span class="hljs-comment">//   update(1,ys[a],ys[b],-1,c);</span><br>    www=station[ys[a]].getleave();<br>    <span class="hljs-keyword">return</span> www;<br>&#125;<br><span class="hljs-type">void</span>  <span class="hljs-title function_">Train::reback</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a,<span class="hljs-built_in">string</span>  b,<span class="hljs-type">int</span> riqi)</span><br>&#123;<br>   <span class="hljs-comment">//update(1,ys[a],ys[b],1,riqi);</span><br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Train::insert</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a,<span class="hljs-type">int</span> d,<span class="hljs-type">int</span> f,<span class="hljs-type">int</span> g,<span class="hljs-type">int</span> h,<span class="hljs-built_in">string</span> w)</span><br>&#123;<br>   Zt <span class="hljs-title function_">tem</span><span class="hljs-params">(a,d,f,g,h)</span>;<br>   <span class="hljs-keyword">if</span>(w==<span class="hljs-string">&quot;END&quot;</span>||w==<span class="hljs-string">&quot;end&quot;</span>||w==<span class="hljs-string">&quot;End&quot;</span>)<br>   &#123;<br>       station.push_back(tem);<br>       ys.insert(<span class="hljs-built_in">make_pair</span>(a,station.size()<span class="hljs-number">-1</span>));<br>   &#125;<br>   <span class="hljs-keyword">else</span> &#123;<br>        station.insert(station.begin()+ys[w],tem);<br>        <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=station.begin()+ys[w]<span class="hljs-number">-1</span>;po!=station.end();po++)<br>        &#123;<br>            ys.insert(<span class="hljs-built_in">make_pair</span>(po-&gt;getsta(),po-station.begin()));<br>        &#125;<br>   &#125;<br><span class="hljs-comment">//    for(int i=0;i&lt;=31;i++)built_tree(0,0,station.size()-1,i);</span><br>&#125;<br><span class="hljs-type">int</span>  <span class="hljs-title function_">Train::cxyp</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a,<span class="hljs-built_in">string</span>  b,<span class="hljs-type">int</span> c)</span><br>&#123;<br>   <span class="hljs-comment">//  return  query(1,ys[a],ys[b],c);</span><br>&#125;<br><span class="hljs-comment">/*</span><br><span class="hljs-comment">void Train::print()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    for(auto po=station.begin();po!=station.end();po++)</span><br><span class="hljs-comment">    &#123;</span><br><span class="hljs-comment">        cout&lt;&lt;</span><br><span class="hljs-comment">    &#125;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-type">bool</span>  <span class="hljs-title function_">Train::del</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span><br>&#123;<br>    <span class="hljs-type">bool</span> flag=<span class="hljs-number">0</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=station.begin();po!=station.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(po-&gt;getsta()==a)<br>        &#123;<br>            station.erase(po);<br>            flag=<span class="hljs-number">1</span>;<br>            <span class="hljs-keyword">break</span>;<br>        &#125;<br>    &#125;<br>    <span class="hljs-keyword">return</span> flag;<br>&#125;<br><span class="hljs-type">void</span>  <span class="hljs-title function_">Train::cx</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span><br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=station.begin();po!=station.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(po-&gt;getsta()==a)<br>        &#123;<br>            po-&gt;print();<br>            po-&gt;printtk();<br>            <span class="hljs-keyword">break</span>;<br>        &#125;<br>    &#125;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Train::setarrive</span><span class="hljs-params">(<span class="hljs-built_in">string</span>   a)</span><br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=station.begin();po!=station.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(po-&gt;getsta()==a)<br>        &#123;<br>            <span class="hljs-type">int</span> a,b;<br>            <span class="hljs-built_in">cin</span>&gt;&gt;a&gt;&gt;b;<br>            po-&gt;setarrive(a,b);<br>            <span class="hljs-keyword">break</span>;<br>        &#125;<br>    &#125;<br>&#125;<br><span class="hljs-type">void</span> Train:: setleave(<span class="hljs-built_in">string</span>  a)<br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=station.begin();po!=station.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(po-&gt;getsta()==a)<br>        &#123;<br>            <span class="hljs-type">int</span> a,b;<br>            <span class="hljs-built_in">cin</span>&gt;&gt;a&gt;&gt;b;<br>            po-&gt;setleave(a,b);<br>            <span class="hljs-keyword">break</span>;<br>        &#125;<br>    &#125;<br>&#125;<br><span class="hljs-type">void</span>  <span class="hljs-title function_">Train::setsta</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span><br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=station.begin();po!=station.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(po-&gt;getsta()==a)<br>        &#123;<br>            po-&gt;setsta(a);<br>            <span class="hljs-keyword">break</span>;<br>        &#125;<br>    &#125;<br>&#125;<br>istream&amp;operator&gt;&gt;(istream&amp; in,Train &amp;a)<br>&#123;<br>    <span class="hljs-comment">//vector&lt;Zt&gt; ww;</span><br>    a.ys.clear();<br>    <span class="hljs-type">int</span> m,n;<br>            Zt demo;<br>    in&gt;&gt;a.train&gt;&gt;n&gt;&gt;m;<span class="hljs-comment">//=0;</span><br>    <span class="hljs-keyword">while</span>(n--)<br>    &#123;<br>        in&gt;&gt;demo;<br>        a.station.push_back(demo);<br>        a.ys.insert(<span class="hljs-built_in">make_pair</span>(demo.getsta(),a.station.size()<span class="hljs-number">-1</span>));<br>      <span class="hljs-comment">//  cout&lt;&lt;ww.station.size()&lt;&lt;endl;</span><br>    &#125;<br>   <span class="hljs-comment">// a.station.swap(ww);</span><br>    <span class="hljs-keyword">while</span>(m--)<br>    &#123;<br>        <span class="hljs-built_in">string</span> w;<br>        in&gt;&gt;w;<br>       a. people .push_back(w);<br>    &#125;<br><span class="hljs-comment">//    for(int i=0;i&lt;=31;i++)a.built_tree(0,0,a.station.size()-1,i);</span><br>    <span class="hljs-keyword">return</span> in;<br>&#125;<br>ostream&amp;operator&lt;&lt;(ostream&amp; out,Train &amp;a)<br>&#123;<br>    out&lt;&lt;a.train&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.station.size()&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.people.size()&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=a.station.begin();po!=a.station.end();po++) out&lt;&lt;*po&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=a.people.begin();po!=a.people.end();po++) out&lt;&lt;*po&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>    out&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">return</span> out;<br>&#125;<br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Train demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    cout&lt;&lt;demo;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Train demo;</span><br><span class="hljs-comment">    short a,b;</span><br><span class="hljs-comment">    int c;</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;c;</span><br><span class="hljs-comment">    demo.insert(a,c);</span><br><span class="hljs-comment">    cin&gt;&gt;b&gt;&gt;c;</span><br><span class="hljs-comment">    demo.insert(b,c);</span><br><span class="hljs-comment">    cout&lt;&lt;demo.cxyp(a,b)&lt;&lt;endl;</span><br><span class="hljs-comment">    demo.buytic(a,b);</span><br><span class="hljs-comment">    cout&lt;&lt;demo.cxyp(a,b)&lt;&lt;endl;</span><br><span class="hljs-comment">    demo.reback(a,b);</span><br><span class="hljs-comment">    cout&lt;&lt;demo.cxyp(a,b)&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Train demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    short int a;</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.cx(a);</span><br><span class="hljs-comment">    demo.del(a);</span><br><span class="hljs-comment">    demo.cx(a);</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.setarrive(a);</span><br><span class="hljs-comment">        demo.cx(a);</span><br><span class="hljs-comment">    demo.setleave(a);</span><br><span class="hljs-comment">        demo.cx(a);</span><br><span class="hljs-comment">    demo.setsta(a);</span><br><span class="hljs-comment">        demo.cx(a);</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Train demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.gettr()&lt;&lt;endl;</span><br><span class="hljs-comment">    string tem;</span><br><span class="hljs-comment">    cin&gt;&gt;tem;</span><br><span class="hljs-comment">    demo.settr(tem);</span><br><span class="hljs-comment">    cout&lt;&lt;demo.gettr()&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;*/</span><br><br><span class="hljs-type">int</span> <span class="hljs-title function_">main</span><span class="hljs-params">()</span><br>&#123;<br>    Train demo;<br>    <span class="hljs-built_in">cin</span>&gt;&gt;demo;<br>    <span class="hljs-built_in">string</span> a,b;<br>    <span class="hljs-type">int</span> c;<br>   <span class="hljs-type">int</span> d,e,f,g;<br>  <span class="hljs-built_in">cin</span>&gt;&gt;a&gt;&gt;d&gt;&gt;e&gt;&gt;f&gt;&gt;g&gt;&gt;b;<br>  demo.insert(a,d,e,f,g,b);<br>    <span class="hljs-built_in">cin</span>&gt;&gt;a&gt;&gt;b&gt;&gt;c;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;demo.cxyp(a,b,c)&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-built_in">cin</span>&gt;&gt;a&gt;&gt;b&gt;&gt;c;<br>     <span class="hljs-built_in">cout</span>&lt;&lt;demo.cxyp(a,b,c)&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    demo.buytic(a,b,c);<br>     <span class="hljs-built_in">cout</span>&lt;&lt;demo.cxyp(a,b,c)&lt;&lt;<span class="hljs-built_in">endl</span>;<br>     demo.reback(a,b,c);<br>      <span class="hljs-built_in">cout</span>&lt;&lt;demo.cxyp(a,b,c)&lt;&lt;<span class="hljs-built_in">endl</span>;<br>&#125;<br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Tick</span> //即使车票，又是记录</span><br><span class="hljs-class">&#123;</span><br>    Time buy;<br>    Time leave; <span class="hljs-comment">//出发时间,用于确定存日志文件</span><br>    <span class="hljs-built_in">string</span>  from;<br>    <span class="hljs-built_in">string</span>  to;<br>    <span class="hljs-built_in">string</span> id;<br>    <span class="hljs-built_in">string</span> name;<br>public:<br>    <span class="hljs-comment">//只有get函数</span><br>    Tick():from(<span class="hljs-string">&quot; &quot;</span>),to(<span class="hljs-string">&quot; &quot;</span>),id(<span class="hljs-string">&quot; &quot;</span>)&#123;&#125;<br>    Tick(Time b,Time l,<span class="hljs-built_in">string</span> f,<span class="hljs-built_in">string</span> t,<span class="hljs-built_in">string</span> i,<span class="hljs-built_in">string</span> w):buy(b),leave(l),from(f),to(t),id(i),name(w)&#123;&#125;<br>    Time&amp;<span class="hljs-title function_">getbuy</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> buy;&#125;<br>    Time&amp;<span class="hljs-title function_">getlea</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> leave;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getfrom</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> from;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getto</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> to;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getid</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> id;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getname</span><span class="hljs-params">()</span>;<span class="hljs-comment">//本来想hash，但是有点复杂</span><br>   <span class="hljs-type">void</span> <span class="hljs-title function_">print</span><span class="hljs-params">()</span>;<br>   <span class="hljs-built_in">string</span> <span class="hljs-title function_">getna</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> name;&#125;<br>    <span class="hljs-type">bool</span> operator ==(Tick &amp;a);<br>    friend istream&amp; operator&gt;&gt;(istream&amp; in,Tick &amp;a );<br>    friend ostream&amp; operator&lt;&lt;(ostream &amp;out,Tick &amp;a );<br>&#125;;<br><span class="hljs-built_in">string</span> <span class="hljs-title function_">Tick::getname</span><span class="hljs-params">()</span><br>&#123;<br>    <span class="hljs-built_in">string</span> w;<br>    <span class="hljs-built_in">stringstream</span> tem;<br>    w.clear();<br>    tem.clear();<br>    tem&lt;&lt;leave.getday();<br>    tem&lt;&lt;leave.getmonth();<br>    tem&lt;&lt;leave.getyear();<br>    tem&gt;&gt;w;<br>    w=w+id+from+to;<br>    <span class="hljs-keyword">return</span> w;<br>&#125;<br><span class="hljs-type">bool</span> Tick::operator ==(Tick &amp;a)<br>&#123;<br>   <span class="hljs-keyword">return</span> a.buy==buy?(a.leave==leave?(from==a.from?(to==a.to?id==a.id:<span class="hljs-number">0</span>):<span class="hljs-number">0</span>):<span class="hljs-number">0</span>):<span class="hljs-number">0</span>;<br>&#125;<br>istream&amp; operator&gt;&gt;(istream &amp;in,Tick &amp;a )<br>&#123;<br>    in&gt;&gt;a.buy&gt;&gt;a.leave&gt;&gt;a.from&gt;&gt;a.to&gt;&gt;a.id&gt;&gt;a.name;<br>    <span class="hljs-keyword">return</span> in;<br>&#125;<br>ostream&amp; operator&lt;&lt;(ostream &amp;out,Tick &amp;a )<br>&#123;<br>    out&lt;&lt;a.buy&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.leave&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.from&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.to&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.id&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.name&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">return</span> out;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Tick::print</span><span class="hljs-params">()</span><br>&#123;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;leave&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;from&lt;&lt;<span class="hljs-string">&quot;-----&gt;&quot;</span>&lt;&lt;to&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;id&lt;&lt;<span class="hljs-built_in">endl</span>;<br>&#125;<span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Tick demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getname()&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Tick demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    cout&lt;&lt;demo;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Time demo1,demo2;</span><br><span class="hljs-comment">    short a,b;</span><br><span class="hljs-comment">    string  id;</span><br><span class="hljs-comment">    cin&gt;&gt;demo1&gt;&gt;demo2&gt;&gt;a&gt;&gt;b&gt;&gt;id;</span><br><span class="hljs-comment">    Tick demo(demo1,demo2,a,b,id);</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getbuy()&lt;&lt;endl;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getlea()&lt;&lt;endl;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getfrom()&lt;&lt;endl;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getto()&lt;&lt;endl;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getid()&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    string a,b,c;</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b&gt;&gt;c;</span><br><span class="hljs-comment">    Time q, e;</span><br><span class="hljs-comment">    cin&gt;&gt;q&gt;&gt;e;</span><br><span class="hljs-comment">    Tick demo(q,e,a,b,c);</span><br><span class="hljs-comment">    cout&lt;&lt;demo;</span><br><span class="hljs-comment">    demo.print();</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Tick demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    demo.print();</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">User</span>//用户信息</span><br><span class="hljs-class">&#123;</span><br>    <span class="hljs-built_in">string</span> name;<br>    <span class="hljs-built_in">string</span> id;  <span class="hljs-comment">//不能改</span><br>    <span class="hljs-built_in">vector</span>&lt;<span class="hljs-built_in">string</span> &gt; tic;<br>    <span class="hljs-built_in">string</span> phone;<br>    <span class="hljs-built_in">string</span> key;<br>    <span class="hljs-type">bool</span> ban;<span class="hljs-comment">//黑名单</span><br>public:<br>    User():name(<span class="hljs-string">&quot;&quot;</span>),id(<span class="hljs-string">&quot;&quot;</span>),phone(<span class="hljs-string">&quot;&quot;</span>)&#123;tic.clear();&#125;<br>    User(<span class="hljs-built_in">string</span> a,<span class="hljs-built_in">string</span> b,<span class="hljs-built_in">string</span> c):name(a),id(b),phone(c)&#123;tic.clear();&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">buytic</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span>&#123;   tic.push_back(a);&#125; <span class="hljs-comment">//只考虑买就行了,判断能不能买在下面的类.</span><br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setph</span><span class="hljs-params">(<span class="hljs-built_in">string</span> p)</span>&#123;    phone=p;&#125;<br>    <span class="hljs-built_in">vector</span>&lt;<span class="hljs-built_in">string</span> &gt;&amp; <span class="hljs-title function_">gettic</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> tic;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getname</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> name;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getphone</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> phone;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getid</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> id;&#125;<br>    <span class="hljs-built_in">string</span> <span class="hljs-title function_">getkey</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> key;&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">del</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span>;  <span class="hljs-comment">//这是系统操作出行后，就看不到订单了。</span><br>    <span class="hljs-type">int</span> <span class="hljs-title function_">getboupiao</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> tic.size();&#125;<br>    <span class="hljs-type">bool</span> <span class="hljs-title function_">getban</span><span class="hljs-params">()</span>&#123;<span class="hljs-keyword">return</span> ban;&#125;<br>    friend istream&amp;operator&gt;&gt;(istream&amp;in,User&amp;a);<br>    friend ostream&amp;operator&lt;&lt;(ostream&amp;out,User&amp;a);<br>&#125;;<br><span class="hljs-type">void</span> <span class="hljs-title function_">User::del</span><span class="hljs-params">(<span class="hljs-built_in">string</span>  a)</span><br>&#123;<br>   <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=tic.begin();po!=tic.end();po++)<br>   &#123;<br>       <span class="hljs-keyword">if</span>(*po==a) tic.erase(po);<br>   &#125;<br>&#125;<br>istream&amp;operator&gt;&gt;(istream&amp;in,User&amp;a)<br>&#123;<br>    <span class="hljs-type">int</span> w;<br>    in&gt;&gt;a.name&gt;&gt;a.id&gt;&gt;a.phone&gt;&gt;a.key&gt;&gt;a.ban&gt;&gt;w;<br>    <span class="hljs-keyword">while</span>(w--)  <span class="hljs-comment">//一个月前的就不读了</span><br>    &#123;<br>        <span class="hljs-built_in">string</span>  q;<br>        in&gt;&gt;q;<br>        <span class="hljs-type">int</span> dday=(q[<span class="hljs-number">0</span>]-<span class="hljs-string">&#x27;0&#x27;</span>)*<span class="hljs-number">10</span>+(q[<span class="hljs-number">1</span>]-<span class="hljs-string">&#x27;0&#x27;</span>);<br>        <span class="hljs-type">int</span> dmonth=(q[<span class="hljs-number">2</span>]-<span class="hljs-string">&#x27;0&#x27;</span>)*<span class="hljs-number">10</span>+(q[<span class="hljs-number">3</span>]-<span class="hljs-string">&#x27;0&#x27;</span>);<br>        <span class="hljs-type">int</span> dyear=(((q[<span class="hljs-number">4</span>]-<span class="hljs-string">&#x27;0&#x27;</span>)*<span class="hljs-number">10</span>+(q[<span class="hljs-number">5</span>]-<span class="hljs-string">&#x27;0&#x27;</span>))*<span class="hljs-number">10</span>+(q[<span class="hljs-number">6</span>]-<span class="hljs-string">&#x27;0&#x27;</span>))*<span class="hljs-number">10</span>+(q[<span class="hljs-number">7</span>]-<span class="hljs-string">&#x27;0&#x27;</span>);<br>        Time <span class="hljs-title function_">tem</span><span class="hljs-params">(dyear,dmonth,dday)</span>;<br>        Time now;<br>        now.loadtime();<br>        <span class="hljs-keyword">if</span>(now&gt;tem) <span class="hljs-keyword">continue</span>;<br>        a.tic.push_back(q);<br>    &#125;<br>    <span class="hljs-keyword">return</span> in;<br>&#125;<br>ostream&amp;operator&lt;&lt;(ostream&amp;out,User&amp;a)<br>&#123;<br>    out&lt;&lt;a.name&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.id&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.phone&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.key&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.ban&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;a.tic.size()&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=a.tic.begin();po!=a.tic.end();po++) out&lt;&lt;*po&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>    <span class="hljs-keyword">return</span> out;<br>&#125;<br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    User demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    cout&lt;&lt;demo;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    string name,id,phone;</span><br><span class="hljs-comment">    cin&gt;&gt;name&gt;&gt;id&gt;&gt;phone;</span><br><span class="hljs-comment">    User demo(name,id,phone);</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getname()&lt;&lt;endl;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getid()&lt;&lt;endl;</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getphone()&lt;&lt;endl;</span><br><span class="hljs-comment">    cin&gt;&gt;phone;</span><br><span class="hljs-comment">    demo.setph(phone);</span><br><span class="hljs-comment">    cout&lt;&lt;demo.getphone()&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    User demo;</span><br><span class="hljs-comment">    int a;</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.buytic(a);</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.buytic(a);</span><br><span class="hljs-comment">    vector&lt;int&gt;   w=demo.gettic();</span><br><span class="hljs-comment">    for(auto po=w.begin();po!=w.end();po++)cout&lt;&lt;*po&lt;&lt;endl;</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.del(a);</span><br><span class="hljs-comment">    w=demo.gettic();</span><br><span class="hljs-comment">    for(auto po=w.begin();po!=w.end();po++)cout&lt;&lt;*po&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Baseque</span> //查询类</span><br><span class="hljs-class">&#123;</span><br>protected:<br>    <span class="hljs-comment">//12306所有的都具有唯一性。</span><br>    <span class="hljs-built_in">vector</span>&lt;Station&gt; station;<span class="hljs-comment">//列车里的int(站台编号）对应station的int；</span><br>    <span class="hljs-built_in">map</span>&lt;<span class="hljs-built_in">string</span>,<span class="hljs-type">int</span>&gt;natosta;<br>    <span class="hljs-built_in">vector</span>&lt;Train&gt; train;<br>    <span class="hljs-built_in">map</span>&lt;<span class="hljs-built_in">string</span>,<span class="hljs-type">int</span>&gt;checitotrain;<br>   <span class="hljs-comment">// vector&lt;User&gt; user;</span><br>  <span class="hljs-comment">//  map&lt;string,int&gt; idtouser;</span><br>  <span class="hljs-comment">//  vector&lt;Tick&gt; tick;</span><br><span class="hljs-comment">//    map&lt;int,int&gt; nutotic;</span><br>public:<br>    Baseque()&#123;station.clear();natosta.clear();train.clear();checitotrain.clear();load();&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">czcc</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-type">int</span> b,<span class="hljs-type">int</span> d)</span>;<br>    <span class="hljs-type">void</span>  <span class="hljs-title function_">cxcx</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>    <span class="hljs-type">bool</span> <span class="hljs-title function_">cxyp</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-built_in">string</span> b,<span class="hljs-type">int</span> c)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">load</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">save</span><span class="hljs-params">()</span>;<br>   <span class="hljs-comment">//void insert()</span><br>    ~Baseque()&#123;save();&#125;<br>&#125;;<br>    <span class="hljs-comment">/*void Baseque;;insert()</span><br><span class="hljs-comment">    &#123;</span><br><span class="hljs-comment">        Train  tem2;</span><br><span class="hljs-comment">        while(    cin&gt;&gt;tem2)</span><br><span class="hljs-comment">            &#123;</span><br><span class="hljs-comment">                 cout&lt;&lt;-2;  //手动调试点</span><br><span class="hljs-comment"></span><br><span class="hljs-comment">         if(tem2.gettr()==&quot;$$&quot;) continue;</span><br><span class="hljs-comment">         train.push_back(tem2);</span><br><span class="hljs-comment">         checitotrain.insert(make_pair(tem2.gettr(),train.size()-1));</span><br><span class="hljs-comment"></span><br><span class="hljs-comment">            &#125;</span><br><span class="hljs-comment">    &#125;*/</span><br><span class="hljs-type">void</span> Baseque ::czcc(<span class="hljs-built_in">string</span> a,<span class="hljs-type">int</span> b,<span class="hljs-type">int</span> d)<br>&#123;<br>    <span class="hljs-built_in">vector</span>&lt;piao&gt;w=station[natosta[a]].quecheci();<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=w.begin();po!=w.end();po++)<br>    &#123;<br>       <span class="hljs-built_in">vector</span>&lt;Zt&gt; q= train[checitotrain[po-&gt;name]].getzt();<br>       <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> pi=q.begin();pi!=q.end();pi++)<br>       &#123;<br>            <span class="hljs-keyword">if</span>(a==pi-&gt;getsta())<br>             &#123;<br>                 <span class="hljs-keyword">if</span>(pi-&gt;getarr()==b||b==<span class="hljs-number">0</span>||pi-&gt;getlea()==d||d==<span class="hljs-number">0</span>)<br>                 &#123;<br>                      <span class="hljs-built_in">cout</span>&lt;&lt;po-&gt;name&lt;&lt;<span class="hljs-built_in">endl</span>;<br>                     <span class="hljs-keyword">if</span>(pi!=q.begin())<br>                     &#123;<br>                            q.begin()-&gt;printl();<br><br>                           <span class="hljs-comment">// cout&lt;&lt;1&lt;&lt;endl;</span><br>                            <span class="hljs-keyword">if</span>(pi==q.end()<span class="hljs-number">-1</span>)<br>                            &#123;<br>                                (q.end()<span class="hljs-number">-1</span>)-&gt;printa();<br>                               <span class="hljs-comment">//cout&lt;&lt;2&lt;&lt;endl;</span><br>                                    <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>                            &#125;<br>                            <span class="hljs-keyword">else</span><br>                            &#123;<br>                                pi-&gt;print();<br>                                  <span class="hljs-comment">//   cout&lt;&lt;endl;</span><br>                                (q.end()<span class="hljs-number">-1</span>)-&gt;printa();<br>                               <span class="hljs-comment">//  cout&lt;&lt;3&lt;&lt;endl;</span><br>                            &#125;<br>                             <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>                     &#125;<br>                     <span class="hljs-keyword">else</span><br>                     &#123;<br>                                q.begin()-&gt;printl();<br>                                (q.end()<span class="hljs-number">-1</span>)-&gt;printa();<br>                                <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>                     &#125;<br>                     <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>                 &#125;<br>             &#125;<br>           <span class="hljs-comment">//  pi-&gt;print();</span><br><br>       &#125;<br>      <span class="hljs-comment">//  cout&lt;&lt;endl;</span><br>    &#125;<br>&#125;<br><span class="hljs-type">void</span> Baseque ::cxcx(<span class="hljs-built_in">string</span> a)  <span class="hljs-comment">//车次查询</span><br>&#123;<br>    <span class="hljs-keyword">if</span>(checitotrain.find(a)==checitotrain.end())<br>    &#123;<br>        <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;NO Train&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>        <span class="hljs-keyword">return</span> ;<br>    &#125; <span class="hljs-comment">//查不到不打印</span><br>    <span class="hljs-built_in">vector</span>&lt;Zt&gt; w=train[checitotrain[a]].getzt();<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=w.begin();po!=w.end();po++)<br>    &#123;<br>        <span class="hljs-built_in">cout</span>&lt;&lt;station[natosta[po-&gt;getsta()]].getname()&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>        <span class="hljs-keyword">if</span>(po!=w.begin()&amp;&amp;po!=w.end()<span class="hljs-number">-1</span>)<br>        &#123;<br>            po-&gt;print();<br>           <span class="hljs-comment">//cout&lt;&lt; po-&gt;getleave().first&lt;&lt;&#x27; &#x27;&lt;&lt;po-&gt;getleave().first;</span><br>        &#125;<br>          <span class="hljs-keyword">else</span> <span class="hljs-keyword">if</span>(po==w.begin())<br>          &#123;<br>               <span class="hljs-built_in">cout</span>&lt;&lt; po-&gt;getleave().first&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt;po-&gt;getleave().first;<br>          &#125;<br>          <span class="hljs-keyword">else</span>   <span class="hljs-built_in">cout</span>&lt;&lt;po-&gt;getarrive().first&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>&lt;&lt; po-&gt;getarrive().second&lt;&lt;<span class="hljs-string">&#x27; &#x27;</span>;<br>    &#125;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>&#125;<br><span class="hljs-type">bool</span> Baseque :: cxyp(<span class="hljs-built_in">string</span> a,<span class="hljs-built_in">string</span> b,<span class="hljs-type">int</span> riqi)<br>&#123;<br>    <span class="hljs-keyword">auto</span> w=station[natosta[a]].quecheci();<br>    <span class="hljs-keyword">auto</span> v=station[natosta[b]].quecheci(); <span class="hljs-comment">//vector&lt;pair&lt;string,int&gt;&gt; checi</span><br>    <span class="hljs-built_in">set</span>&lt;piao&gt;tem;<br>    <span class="hljs-built_in">vector</span>&lt;piao&gt;temp;<br>    temp.clear();<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=w.begin();po!=w.end();po++) tem.insert(*po);<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=v.begin();po!=v.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(tem.insert(*po).second==<span class="hljs-number">0</span>) temp.push_back(*po);<br>    &#125;<br>    <span class="hljs-keyword">if</span>(temp.size()==<span class="hljs-number">0</span>)<br>    &#123;<br>        <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;No ticket&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>        <span class="hljs-keyword">return</span> <span class="hljs-number">0</span> ;<br>    &#125;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=temp.begin();po!=temp.end();po++)<br>    &#123;<br>       <span class="hljs-keyword">auto</span> x= train[checitotrain[po-&gt;name]].getzt();<br>       <span class="hljs-type">int</span> mini=po-&gt;sum[riqi];<br>       <span class="hljs-type">int</span> ss=train[checitotrain[po-&gt;name]].cxyp(a,b,riqi);<br>       mini=min(mini,ss);<br>       <span class="hljs-built_in">cout</span>&lt;&lt;train[checitotrain[po-&gt;name]].gettr()&lt;&lt;<span class="hljs-built_in">endl</span>;;<br>       <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> pi=x.begin();pi!=x.end();pi++) <span class="hljs-comment">//336</span><br>       &#123;<br>            <span class="hljs-comment">//cout&lt;&lt;s</span><br>            pi-&gt;print();<br>       &#125;<br>       <span class="hljs-built_in">cout</span>&lt;&lt;mini&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    &#125;<br>    <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Baseque::load</span><span class="hljs-params">()</span><br> &#123;<br>     <span class="hljs-type">int</span> x,y,n;<br>    ifstream <span class="hljs-title function_">in1</span><span class="hljs-params">(<span class="hljs-string">&quot;station.txt&quot;</span>,ios::in)</span>;<br>    in1&gt;&gt;n;<br>     <span class="hljs-keyword">while</span>(    n--)<br>     &#123;<br>              Station tem1;<br>          in1&gt;&gt;tem1;<br>            <span class="hljs-comment">//      cout&lt;&lt;-1; 手动调试点</span><br>         <span class="hljs-keyword">if</span>(tem1.getname()==<span class="hljs-string">&quot;$$&quot;</span>) <span class="hljs-keyword">continue</span>;<br>         station.push_back(tem1);<br>         natosta.insert(<span class="hljs-built_in">make_pair</span>(tem1.getname(),station.size()<span class="hljs-number">-1</span>));<br>     <span class="hljs-comment">//    cout&lt;&lt;1;</span><br><br>     &#125;<br>     in1.close();<br>     ifstream <span class="hljs-title function_">in2</span><span class="hljs-params">(<span class="hljs-string">&quot;train.txt&quot;</span>,ios::in)</span>;<br><br>     in2&gt;&gt;n;<br>       <span class="hljs-keyword">while</span>(n--   )<br>    &#123;<br>             Train tem2;<br>         in2&gt;&gt;tem2;<br>                <span class="hljs-comment">// cout&lt;&lt;-2;  //手动调试点</span><br><br>         <span class="hljs-keyword">if</span>(tem2.gettr()==<span class="hljs-string">&quot;$$&quot;</span>) <span class="hljs-keyword">continue</span>;<br>         train.push_back(tem2);<br>         checitotrain.insert(<span class="hljs-built_in">make_pair</span>(tem2.gettr(),train.size()<span class="hljs-number">-1</span>));<br>    &#125;<br>    in2.close();<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Baseque::save</span><span class="hljs-params">()</span><br> &#123;<br>  ofstream <span class="hljs-title function_">out1</span><span class="hljs-params">(<span class="hljs-string">&quot;station.txt&quot;</span>,ios::out)</span>;<br>  out1&lt;&lt;station.size()&lt;&lt;<span class="hljs-built_in">endl</span>;<br>     <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=station.begin();po!=station.end();po++)<br>        out1&lt;&lt;*po&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    out1.close();<br>    ofstream <span class="hljs-title function_">out2</span><span class="hljs-params">(<span class="hljs-string">&quot;train.txt&quot;</span>,ios::out)</span>;<br>    out2&lt;&lt;train.size()&lt;&lt;<span class="hljs-built_in">endl</span>;<br>     <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=train.begin();po!=train.end();po++)<br>        out2&lt;&lt;*po&lt;&lt;<span class="hljs-built_in">endl</span>;<br>        out2.close();<br> &#125;<br> <span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Baseque demo;</span><br><span class="hljs-comment">    cin&gt;&gt;demo;</span><br><span class="hljs-comment">    cout&lt;&lt;demo;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Baseque demo;</span><br><span class="hljs-comment">    string a;</span><br><span class="hljs-comment">    int c;</span><br><span class="hljs-comment">    int b;</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b&gt;&gt;c;</span><br><span class="hljs-comment">    demo.czcc(a,b,c);</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b&gt;&gt;c; //一天分四个时段查询。5就查不到</span><br><span class="hljs-comment">    demo.czcc(a,b,c);</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Baseque demo;</span><br><span class="hljs-comment">    string a;</span><br><span class="hljs-comment">    int c;</span><br><span class="hljs-comment">    int b;</span><br><span class="hljs-comment">    cin&gt;&gt;a;//&gt;&gt;b&gt;&gt;c;</span><br><span class="hljs-comment">    demo.cxcx(a);</span><br><span class="hljs-comment">    cin&gt;&gt;a;//&gt;&gt;b&gt;&gt;c;</span><br><span class="hljs-comment">    demo.cxcx(a);</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Baseque demo;</span><br><span class="hljs-comment">    string a,b;</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b;</span><br><span class="hljs-comment">    demo.cxyp(a,b);</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Baseque demo;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Client</span>:</span>public Baseque<br>&#123;<br>protected:<br>    <span class="hljs-built_in">vector</span>&lt;User&gt; user;<br>    <span class="hljs-built_in">map</span>&lt;<span class="hljs-built_in">string</span>,<span class="hljs-type">int</span>&gt; idtouse;<br>    <span class="hljs-built_in">vector</span>&lt;Tick&gt;tick;<br>    <span class="hljs-built_in">map</span>&lt;<span class="hljs-built_in">string</span>,<span class="hljs-type">int</span>&gt; hashtotick;<br>    <span class="hljs-type">int</span> now;<span class="hljs-comment">//用于记录当前用户</span><br>    <span class="hljs-built_in">string</span> now2;<br>public:<br>        Client()&#123;load2();&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">load2</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">save2</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">bool</span> <span class="hljs-title function_">buytic</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-built_in">string</span> b,<span class="hljs-type">int</span> c)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">reback</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">replacetic</span><span class="hljs-params">()</span>;<br>    virtual <span class="hljs-type">void</span> <span class="hljs-title function_">login</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setphone</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">printmp</span><span class="hljs-params">()</span>;<br>    ~Client()&#123;save2();&#125;<br>&#125;;<br> <span class="hljs-type">void</span> <span class="hljs-title function_">Client::printmp</span><span class="hljs-params">()</span><br> &#123;<br>    <span class="hljs-keyword">auto</span> ww=user[now].gettic();<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=ww.begin();po!=ww.end();po++)<br>    &#123;<br>        <span class="hljs-built_in">cout</span>&lt;&lt;po-ww.begin()+<span class="hljs-number">1</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>       tick[ hashtotick[*po]].print();<br>    &#125;<br> &#125;<br><span class="hljs-type">bool</span> <span class="hljs-title function_">Client::buytic</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a,<span class="hljs-built_in">string</span> b,<span class="hljs-type">int</span> c)</span> <span class="hljs-comment">//先查后买，查不到不能买。</span><br>&#123;<br>    <span class="hljs-keyword">if</span>(!(cxyp(a,b,c)))&#123;<span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;无票&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<span class="hljs-keyword">return</span> <span class="hljs-number">0</span>;&#125;<br>    <span class="hljs-keyword">if</span>(user[now].getboupiao()&gt;<span class="hljs-number">5</span>||user[now].getban())<br>    &#123;<br>        <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;购票限制&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>        <span class="hljs-keyword">return</span> <span class="hljs-number">0</span>;<br>    &#125;<br>   <span class="hljs-keyword">else</span><br>    &#123;<br>        <span class="hljs-built_in">string</span> id;<br>        <span class="hljs-built_in">cin</span>&gt;&gt;id;<br>        <span class="hljs-built_in">pair</span>&lt;<span class="hljs-type">int</span>,<span class="hljs-type">int</span>&gt;www=train[checitotrain[id]].buytic(a,b,c);<br>        station[natosta[a]].buytic(a,c);<br>        Time no1,no2;<br>        no1.loadtime();<br>        no2.loadtime();<br>        no2.seth(www.first,www.second);<br>        <span class="hljs-keyword">if</span>(no2.getday()&lt;c) no2.setmonth(no2.getmonth()+<span class="hljs-number">1</span>);<br>        Tick <span class="hljs-title function_">tem</span><span class="hljs-params">(no1,no2,a,b,now2,id)</span>;<br>        tick.push_back(tem);<br>        hashtotick.insert(<span class="hljs-built_in">make_pair</span>(tem.getname(),tick.size()<span class="hljs-number">-1</span>));<br>        user[now].buytic(tem.getname());<br>    &#125;<br>    <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Client::reback</span><span class="hljs-params">()</span> <span class="hljs-comment">//先查后买，查不到不能买。</span><br>&#123;<br>        printmp();<br>        <span class="hljs-built_in">string</span> id=now2;<br>        <span class="hljs-type">int</span> n;<br>        <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;退哪一张票&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>        <span class="hljs-built_in">cin</span>&gt;&gt;n;<br>        n=n<span class="hljs-number">-1</span>;<br>    <span class="hljs-keyword">auto</span> ww=user[now].gettic();<br> <span class="hljs-built_in">string</span> a=tick[ hashtotick[ww[n]]].getfrom();<br>         <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-number">1</span>&lt;&lt;<span class="hljs-built_in">endl</span>;;<br>      <span class="hljs-built_in">string</span> b=tick[ hashtotick[ww[n]]].getto();<br>         <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-number">2</span>&lt;&lt;<span class="hljs-built_in">endl</span>;;<br>       <span class="hljs-type">int</span> c=tick[ hashtotick[ww[n]]].getlea().getday();<br>         <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-number">3</span>&lt;&lt;<span class="hljs-built_in">endl</span>;;<br>        train[checitotrain[id]].reback(a,b,c);<br>        <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-number">4</span>&lt;&lt;<span class="hljs-built_in">endl</span>;;<br>         <span class="hljs-built_in">string</span> e=tick[ hashtotick[ww[n]]].getna();<br>       station[natosta[a]].rebac(e,c);<br>        <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-number">5</span>&lt;&lt;<span class="hljs-built_in">endl</span>;;<br>     <span class="hljs-comment">// tick.erase(hashtotick[ww[n]]+tick.begin());</span><br><br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Client::replacetic</span><span class="hljs-params">()</span><br>&#123;<br>    <span class="hljs-built_in">string</span> a,b,id;<br>    <span class="hljs-type">int</span> c;<br>    <span class="hljs-built_in">cin</span>&gt;&gt;a&gt;&gt;b&gt;&gt;c;<br>  <span class="hljs-keyword">if</span>(  buytic(a,b,c))<br>   &#123;<br>        <span class="hljs-built_in">cin</span>&gt;&gt;a&gt;&gt;b&gt;&gt;c;<br>        reback();<br>   &#125;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Client::setphone</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span><br>&#123;<br>    user[now].setph(a);<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Client::login</span><span class="hljs-params">()</span><br>&#123;<br>    <span class="hljs-built_in">string</span> phone;<br>    <span class="hljs-built_in">string</span> key;<br>    <span class="hljs-keyword">while</span>(<span class="hljs-built_in">cin</span>&gt;&gt;phone&gt;&gt;key)<br>    &#123;<br>           <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=user.begin();po!=user.end();po++)<br>           &#123;<br>               <span class="hljs-keyword">if</span>(po-&gt;getphone()==phone)<br>                   <span class="hljs-keyword">if</span>(po-&gt;getkey()==key)<br>                    &#123;<br>                        <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;Login prosperity&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>                        now=po-user.begin();<br>                        now2=po-&gt;getid();<br>                        <span class="hljs-keyword">return</span> ;<br>                    &#125;<br>           &#125;<br>           <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;Wrong password&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    &#125;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Client::load2</span><span class="hljs-params">()</span><br>&#123;<br>    ifstream <span class="hljs-title function_">in</span><span class="hljs-params">(<span class="hljs-string">&quot;user.txt&quot;</span>,ios::in)</span>;<br>    <span class="hljs-type">int</span> n;<br>    <span class="hljs-keyword">if</span>(!in) <span class="hljs-keyword">return</span> ;<br>    in&gt;&gt;n;<br>    <span class="hljs-keyword">while</span>(n--)<br>    &#123;<br>        User tem;<br>        in&gt;&gt;tem;<br>        user.push_back(tem);<br>        idtouse.insert(<span class="hljs-built_in">make_pair</span>(tem.getname(),user.size()<span class="hljs-number">-1</span>));<br>    &#125;<br>    in.close();<br>    ifstream <span class="hljs-title function_">in2</span><span class="hljs-params">(<span class="hljs-string">&quot;tick.txt&quot;</span>,ios::in)</span>;<br>    <span class="hljs-keyword">if</span>(!in2) <span class="hljs-keyword">return</span> ;<br>    in2&gt;&gt;n;<br>    <span class="hljs-keyword">while</span>(n--)<br>    &#123;<br>        Tick tem;<br>        in2&gt;&gt;tem;<br>        <span class="hljs-keyword">if</span>(tem.getname()==<span class="hljs-string">&quot;$$$&quot;</span>) <span class="hljs-keyword">continue</span>;<br>        tick.push_back(tem);<br>        hashtotick.insert(<span class="hljs-built_in">make_pair</span>(tem.getname(),tick.size()<span class="hljs-number">-1</span>));<br>    &#125;<br>    in.close();<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Client::save2</span><span class="hljs-params">()</span><br>&#123;<br>    ofstream <span class="hljs-title function_">out</span><span class="hljs-params">(<span class="hljs-string">&quot;user.txt&quot;</span>,ios::out)</span>;<br>    out&lt;&lt;user.size()&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=user.begin();po!=user.end();po++) out&lt;&lt;*po&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    out.close();<br>    ofstream <span class="hljs-title function_">out2</span><span class="hljs-params">(<span class="hljs-string">&quot;tick.txt&quot;</span>,ios::out)</span>;<br>    <span class="hljs-built_in">stringstream</span> sss;<br>    Time now;<br>    now.loadtime();<br>    <span class="hljs-built_in">string</span> temp;<br>    sss&lt;&lt;now.getyear()&lt;&lt;<span class="hljs-string">&quot;年&quot;</span>&lt;&lt;now.getmonth()&lt;&lt;<span class="hljs-string">&quot;月&quot;</span>&lt;&lt;now.getday()&lt;&lt;<span class="hljs-string">&quot;日&quot;</span>;<br>    sss&gt;&gt;temp;<br>    ofstream <span class="hljs-title function_">out3</span><span class="hljs-params">(temp,ios::out)</span>;   <span class="hljs-comment">//做过的车，就存到日志文件不在读取。</span><br>    <span class="hljs-type">int</span> sum=<span class="hljs-number">0</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=tick.begin();po!=tick.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(now&gt;po-&gt;getlea())<br>        &#123;<br>            out3&lt;&lt;*po&lt;&lt;<span class="hljs-built_in">endl</span>;<br>        &#125;<br>        <span class="hljs-keyword">else</span> sum++;<br>    &#125;<br>    out3.close();<br>    out2&lt;&lt;sum&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=tick.begin();po!=tick.end();po++)<br>    &#123;<br>        <span class="hljs-keyword">if</span>(now&gt;po-&gt;getlea()) <span class="hljs-keyword">continue</span>;<br>        out2&lt;&lt;*po&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    &#125;<br>    out2.close();<br>&#125;<br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Client demo;</span><br><span class="hljs-comment">    //demo.login();</span><br><span class="hljs-comment">&#125;*/</span><br><br><span class="hljs-comment">/*int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Client demo;</span><br><span class="hljs-comment">    demo.login();//登陆密码18053176044 123456</span><br><span class="hljs-comment">    string a,b;</span><br><span class="hljs-comment">    int riqi;</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b&gt;&gt;riqi;</span><br><span class="hljs-comment">    demo.buytic(a,b,riqi);</span><br><span class="hljs-comment">    demo.cxyp(a,b,riqi);</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Client demo;</span><br><span class="hljs-comment">    demo.login();</span><br><span class="hljs-comment">    string a,b;</span><br><span class="hljs-comment">    int riqi;</span><br><span class="hljs-comment">    cin&gt;&gt;a&gt;&gt;b&gt;&gt;riqi;</span><br><span class="hljs-comment">    demo.buytic(a,b,riqi);</span><br><span class="hljs-comment">    demo.reback();</span><br><span class="hljs-comment">    demo.cxyp(a,b,riqi);</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">Admin</span>:</span>public Client<br>&#123;<br>public:<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">login</span><span class="hljs-params">()</span>&#123;&#125;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">insertsta</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">bool</span> <span class="hljs-title function_">delsta</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">setsta</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">inserttr</span><span class="hljs-params">()</span>;<br>    <span class="hljs-type">bool</span> <span class="hljs-title function_">deltr</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>    <span class="hljs-type">void</span> <span class="hljs-title function_">settr</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span>;<br>&#125;;<br><span class="hljs-type">void</span> Admin:: insertsta()<br>&#123;<br>    Station tem1;<br>    <span class="hljs-built_in">cin</span>&gt;&gt;tem1;<br>    station.push_back(tem1);<br>    natosta.insert(<span class="hljs-built_in">make_pair</span>(tem1.getname(),station.size()<span class="hljs-number">-1</span>));<br>&#125;<br><span class="hljs-type">bool</span> <span class="hljs-title function_">Admin::delsta</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span><br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=station.begin();po!=station.end();po++)<br>    <span class="hljs-keyword">if</span>(po-&gt;getname()==a)<br>    &#123;<br>        <span class="hljs-built_in">vector</span>&lt;piao&gt; ww=po-&gt;quecheci();<br>        <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> pi=ww.begin();pi!=ww.end();pi++)<br>            train[checitotrain[pi-&gt;name]].del(a);<br>        station.erase(po);<br>        <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>    &#125;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;无此车站&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">return</span> <span class="hljs-number">0</span>;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Admin::setsta</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span><br>&#123;<br>    <span class="hljs-keyword">if</span>(!delsta(a))<span class="hljs-keyword">return</span> ;<br>    insertsta();<br>    <span class="hljs-keyword">return</span> ;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Admin::inserttr</span><span class="hljs-params">()</span><br>&#123;<br>    Train tem2;<br>    <span class="hljs-built_in">cin</span>&gt;&gt;tem2;<br>    train.push_back(tem2);<br>    checitotrain.insert(<span class="hljs-built_in">make_pair</span>(tem2.gettr(),train.size()<span class="hljs-number">-1</span>));<br>    <span class="hljs-keyword">return</span> ;<br>&#125;<br><span class="hljs-type">bool</span> <span class="hljs-title function_">Admin::deltr</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span><br>&#123;<br>    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> po=train.begin();po!=train.end();po++)<br>    <span class="hljs-keyword">if</span>(po-&gt;gettr()==a)<br>    &#123;<br>        <span class="hljs-built_in">vector</span>&lt;Zt&gt; ww=po-&gt;getzt();<br>        <span class="hljs-keyword">for</span>(<span class="hljs-keyword">auto</span> pi=ww.begin();pi!=ww.end();pi++)<br>            station[natosta[pi-&gt;getsta()]].del(a);<br>        train.erase(po);<br>                <span class="hljs-keyword">return</span> <span class="hljs-number">1</span>;<br>    &#125;<br>    <span class="hljs-built_in">cout</span>&lt;&lt;<span class="hljs-string">&quot;无此高铁&quot;</span>&lt;&lt;<span class="hljs-built_in">endl</span>;<br>    <span class="hljs-keyword">return</span> <span class="hljs-number">0</span>;<br>&#125;<br><span class="hljs-type">void</span> <span class="hljs-title function_">Admin::settr</span><span class="hljs-params">(<span class="hljs-built_in">string</span> a)</span><br>&#123;<br>    <span class="hljs-keyword">if</span>(!deltr(a))<span class="hljs-keyword">return</span> ;<br>    inserttr();<br>&#125;<br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Admin demo;</span><br><span class="hljs-comment">    demo.insertsta();</span><br><span class="hljs-comment">    string a;</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.delsta(a);</span><br><span class="hljs-comment">  //  cout&lt;&lt;1&lt;&lt;endl;</span><br><span class="hljs-comment">    demo.insertsta();</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.setsta(a);</span><br><span class="hljs-comment">   // cout&lt;&lt;2&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Admin demo;</span><br><span class="hljs-comment">    demo.inserttr();</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Admin demo;</span><br><span class="hljs-comment">    demo.inserttr();</span><br><span class="hljs-comment">     string a;</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.deltr(a);</span><br><span class="hljs-comment">&#125;*/</span><br><span class="hljs-comment">/*</span><br><span class="hljs-comment">int main()</span><br><span class="hljs-comment">&#123;</span><br><span class="hljs-comment">    Admin demo;</span><br><span class="hljs-comment">    demo.inserttr();</span><br><span class="hljs-comment">    string a;</span><br><span class="hljs-comment">    cin&gt;&gt;a;</span><br><span class="hljs-comment">    demo.settr(a);</span><br><span class="hljs-comment"> //   cout&lt;&lt;2&lt;&lt;endl;</span><br><span class="hljs-comment">&#125;</span><br><span class="hljs-comment">*/</span><br><br></code></pre></td></tr></table></figure>

                
              </div>
            
            <hr/>
            <div>
              <div class="post-metas my-3">
  
    <div class="post-meta mr-3 d-flex align-items-center">
      <i class="iconfont icon-category"></i>
      

<span class="category-chains">
  
  
    
      <span class="category-chain">
        
  <a href="/categories/C-C%E8%AF%AD%E8%A8%80/" class="category-chain-item">C++&amp;C语言</a>
  
  

      </span>
    
  
</span>

    </div>
  
  
</div>


              
  

  <div class="license-box my-3">
    <div class="license-title">
      <div>『C++&amp;C语言』C++课程设计，12306模拟写起来就是这么粗暴</div>
      <div>http://example.com/2023/12/06/『C++&amp;C语言』C++课程设计，12306模拟写起来就是这么粗暴/</div>
    </div>
    <div class="license-meta">
      
        <div class="license-meta-item">
          <div>作者</div>
          <div>Chiam</div>
        </div>
      
      
        <div class="license-meta-item license-meta-date">
          <div>发布于</div>
          <div>2023年12月6日</div>
        </div>
      
      
      
        <div class="license-meta-item">
          <div>许可协议</div>
          <div>
            
              
              
                <a class="print-no-link" target="_blank" href="https://creativecommons.org/licenses/by/4.0/">
                  <span class="hint--top hint--rounded" aria-label="BY - 署名">
                    <i class="iconfont icon-by"></i>
                  </span>
                </a>
              
            
          </div>
        </div>
      
    </div>
    <div class="license-icon iconfont"></div>
  </div>



              
                <div class="post-prevnext my-3">
                  <article class="post-prev col-6">
                    
                    
                      <a href="/2023/12/06/%E3%80%8EC++&amp;C%E8%AF%AD%E8%A8%80%E3%80%8FC++%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1%E8%AF%A6%E8%A7%A3-12306%E7%9A%84%E6%A8%A1%E6%8B%9F%E5%AE%9E%E7%8E%B0/" title="『C++&amp;C语言』C++课程设计详解-12306的模拟实现">
                        <i class="iconfont icon-arrowleft"></i>
                        <span class="hidden-mobile">『C++&amp;C语言』C++课程设计详解-12306的模拟实现</span>
                        <span class="visible-mobile">上一篇</span>
                      </a>
                    
                  </article>
                  <article class="post-next col-6">
                    
                    
                      <a href="/2023/12/06/%E3%80%8EC++&amp;C%E8%AF%AD%E8%A8%80%E3%80%8FC++%E8%8E%B7%E5%8F%96%E5%BD%93%E5%89%8D%E7%B3%BB%E7%BB%9F%E6%97%B6%E9%97%B4%E5%B9%B6%E6%A0%BC%E5%BC%8F%E5%8C%96%E8%BE%93%E5%87%BA/" title="『C++&amp;C语言』C++获取当前系统时间并格式化输出">
                        <span class="hidden-mobile">『C++&amp;C语言』C++获取当前系统时间并格式化输出</span>
                        <span class="visible-mobile">下一篇</span>
                        <i class="iconfont icon-arrowright"></i>
                      </a>
                    
                  </article>
                </div>
              
            </div>

            
  
  
    <article id="comments" lazyload>
      
  <div id="valine"></div>
  <script type="text/javascript">
    Fluid.utils.loadComments('#valine', function() {
      Fluid.utils.createScript('https://lib.baomitu.com/valine/1.5.1/Valine.min.js', function() {
        var options = Object.assign(
          {"appId":"fIfc7WqUDZohlQuPc2lz5mJy-MdYXbMMI","appKey":"zjlAG3ZA3o4cBHVAkjzc2Z20","path":"window.location.pathname","placeholder":"留言仅限讨论，禁止广告等行为","avatar":"retro","meta":["nick","mail","link"],"requiredFields":[],"pageSize":10,"lang":"zh-CN","highlight":false,"recordIP":false,"serverURLs":"https://fifc7wqu.api.lncldglobal.com","emojiCDN":null,"emojiMaps":null,"enableQQ":false},
          {
            el: "#valine",
            path: window.location.pathname
          }
        )
        new Valine(options);
        Fluid.utils.waitElementVisible('#valine .vcontent', () => {
          var imgSelector = '#valine .vcontent img:not(.vemoji)';
          Fluid.plugins.imageCaption(imgSelector);
          Fluid.plugins.fancyBox(imgSelector);
        })
      });
    });
  </script>
  <noscript>Please enable JavaScript to view the comments</noscript>


    </article>
  


          </article>
        </div>
      </div>
    </div>

    <div class="side-col d-none d-lg-block col-lg-2">
      
  <aside class="sidebar" style="margin-left: -1rem">
    <div id="toc">
  <p class="toc-header">
    <i class="iconfont icon-list"></i>
    <span>目录</span>
  </p>
  <div class="toc-body" id="toc-body"></div>
</div>



  </aside>


    </div>
  </div>
</div>





  



  



  



  



  







    

    
      <a id="scroll-top-button" aria-label="TOP" href="#" role="button">
        <i class="iconfont icon-arrowup" aria-hidden="true"></i>
      </a>
    

    
      <div class="modal fade" id="modalSearch" tabindex="-1" role="dialog" aria-labelledby="ModalLabel"
     aria-hidden="true">
  <div class="modal-dialog modal-dialog-scrollable modal-lg" role="document">
    <div class="modal-content">
      <div class="modal-header text-center">
        <h4 class="modal-title w-100 font-weight-bold">搜索</h4>
        <button type="button" id="local-search-close" class="close" data-dismiss="modal" aria-label="Close">
          <span aria-hidden="true">&times;</span>
        </button>
      </div>
      <div class="modal-body mx-3">
        <div class="md-form mb-5">
          <input type="text" id="local-search-input" class="form-control validate">
          <label data-error="x" data-success="v" for="local-search-input">关键词</label>
        </div>
        <div class="list-group" id="local-search-result"></div>
      </div>
    </div>
  </div>
</div>

    

    
  </main>

  <footer>
    <div class="footer-inner">
  
    <div class="footer-content">
       <meta name="referrer" content="no-referrer" /> <footer id="footer" role="contentinfo"> <div class="divider"> <div class="wall"></div> <img class="animals" src="/img/footer_animals_new.png" srcset="/img/loading.gif" lazyload alt="Footer Animals"> </div> <div class="container" data-index="450"> <p> <a href="https://chiamzhang.github.io" target="_blank">DogEgg</a> <i class="iconfont icon-love"></i> <a href="#" target="_blank">LittePig</a> </p> <p> Powered by  <a href="https://hexo.io" target="_blank" rel="nofollow noopener"><span>Hexo</span></a> <i class="iconfont icon-pen"></i> Theme  <a href="https://github.com/fluid-dev/hexo-theme-fluid" target="_blank" rel="nofollow noopener"><span>Fluid</span></a> </p> </div> </footer> 
    </div>
  
  
  
  
</div>

  </footer>

  <!-- Scripts -->
  
  <script  src="https://lib.baomitu.com/nprogress/0.2.0/nprogress.min.js" ></script>
  <link  rel="stylesheet" href="https://lib.baomitu.com/nprogress/0.2.0/nprogress.min.css" />

  <script>
    NProgress.configure({"showSpinner":false,"trickleSpeed":100})
    NProgress.start()
    window.addEventListener('load', function() {
      NProgress.done();
    })
  </script>


<script  src="https://lib.baomitu.com/jquery/3.6.4/jquery.min.js" ></script>
<script  src="https://lib.baomitu.com/twitter-bootstrap/4.6.1/js/bootstrap.min.js" ></script>
<script  src="/js/events.js" ></script>
<script  src="/js/plugins.js" ></script>


  <script  src="https://lib.baomitu.com/typed.js/2.0.12/typed.min.js" ></script>
  <script>
    (function (window, document) {
      var typing = Fluid.plugins.typing;
      var subtitle = document.getElementById('subtitle');
      if (!subtitle || !typing) {
        return;
      }
      var text = subtitle.getAttribute('data-typed-text');
      
        typing(text);
      
    })(window, document);
  </script>




  
    <script  src="/js/img-lazyload.js" ></script>
  




  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/tocbot/4.20.1/tocbot.min.js', function() {
    var toc = jQuery('#toc');
    if (toc.length === 0 || !window.tocbot) { return; }
    var boardCtn = jQuery('#board-ctn');
    var boardTop = boardCtn.offset().top;

    window.tocbot.init(Object.assign({
      tocSelector     : '#toc-body',
      contentSelector : '.markdown-body',
      linkClass       : 'tocbot-link',
      activeLinkClass : 'tocbot-active-link',
      listClass       : 'tocbot-list',
      isCollapsedClass: 'tocbot-is-collapsed',
      collapsibleClass: 'tocbot-is-collapsible',
      scrollSmooth    : true,
      includeTitleTags: true,
      headingsOffset  : -boardTop,
    }, CONFIG.toc));
    if (toc.find('.toc-list-item').length > 0) {
      toc.css('visibility', 'visible');
    }

    Fluid.events.registerRefreshCallback(function() {
      if ('tocbot' in window) {
        tocbot.refresh();
        var toc = jQuery('#toc');
        if (toc.length === 0 || !tocbot) {
          return;
        }
        if (toc.find('.toc-list-item').length > 0) {
          toc.css('visibility', 'visible');
        }
      }
    });
  });
</script>


  <script src=https://lib.baomitu.com/clipboard.js/2.0.11/clipboard.min.js></script>

  <script>Fluid.plugins.codeWidget();</script>


  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/anchor-js/4.3.1/anchor.min.js', function() {
    window.anchors.options = {
      placement: CONFIG.anchorjs.placement,
      visible  : CONFIG.anchorjs.visible
    };
    if (CONFIG.anchorjs.icon) {
      window.anchors.options.icon = CONFIG.anchorjs.icon;
    }
    var el = (CONFIG.anchorjs.element || 'h1,h2,h3,h4,h5,h6').split(',');
    var res = [];
    for (var item of el) {
      res.push('.markdown-body > ' + item.trim());
    }
    if (CONFIG.anchorjs.placement === 'left') {
      window.anchors.options.class = 'anchorjs-link-left';
    }
    window.anchors.add(res.join(', '));

    Fluid.events.registerRefreshCallback(function() {
      if ('anchors' in window) {
        anchors.removeAll();
        var el = (CONFIG.anchorjs.element || 'h1,h2,h3,h4,h5,h6').split(',');
        var res = [];
        for (var item of el) {
          res.push('.markdown-body > ' + item.trim());
        }
        if (CONFIG.anchorjs.placement === 'left') {
          anchors.options.class = 'anchorjs-link-left';
        }
        anchors.add(res.join(', '));
      }
    });
  });
</script>


  
<script>
  Fluid.utils.createScript('https://lib.baomitu.com/fancybox/3.5.7/jquery.fancybox.min.js', function() {
    Fluid.plugins.fancyBox();
  });
</script>


  <script>Fluid.plugins.imageCaption();</script>

  <script  src="/js/local-search.js" ></script>




  
<script src="/js/love.js"></script>
<script src="/js/funnyTitle.js"></script>
<script src="/js/backTop.js"></script>
<script src="//cdn.jsdelivr.net/gh/bynotes/texiao/source/js/xiaoxuehua.js"></script>



<!-- 主题的启动项，将它保持在最底部 -->
<!-- the boot of the theme, keep it at the bottom -->
<script  src="/js/boot.js" ></script>


  

  <noscript>
    <div class="noscript-warning">博客在允许 JavaScript 运行的环境下浏览效果更佳</div>
  </noscript>
<script src="/live2dw/lib/L2Dwidget.min.js?094cbace49a39548bed64abff5988b05"></script><script>L2Dwidget.init({"pluginRootPath":"live2dw/","pluginJsPath":"lib/","pluginModelPath":"assets/","tagMode":false,"debug":false,"model":{"jsonPath":"/live2dw/assets/wanko.model.json"},"display":{"position":"left","width":150,"height":150,"hOffset":20,"vOffset":0},"mobile":{"show":false,"scale":0.5},"react":{"opacity":0.9},"log":false});</script></body>
</html>
